[
{
"type": "ExpressionStatement",
"expression": {
"type": "Literal",
"value": "use strict"
},
"directive": "use strict"
},
{
"type": "VariableDeclaration",
"kind": "const",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "ion_Null"
},
"init": {
"type": "Literal",
"value": "Object.freeze({
is(value) {
return value == null
}
})",
"verbatim": "Object.freeze({
is(value) {
return value == null
}
})"
}
}
]
},
{
"type": "VariableDeclaration",
"kind": "const",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "ion_Boolean"
},
"init": {
"type": "Literal",
"value": "Object.freeze({
is(value) {
return value === true || value === false
}
})",
"verbatim": "Object.freeze({
is(value) {
return value === true || value === false
}
})"
}
}
]
},
{
"type": "VariableDeclaration",
"kind": "const",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "ion_ast_Node"
},
"init": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "freeze"
}
},
"arguments": [
{
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "assign"
}
},
"arguments": [
{
"type": "ClassExpression",
"id": {
"type": "Identifier",
"name": "Node"
},
"superClass": null,
"body": {
"type": "ClassBody",
"body": [
{
"type": "MethodDefinition",
"kind": "constructor",
"key": {
"type": "Identifier",
"name": "constructor"
},
"value": {
"type": "FunctionExpression",
"id": null,
"params": [],
"body": {
"type": "BlockStatement",
"body": [
{
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "Literal",
"value": "Node is abstract"
}
]
}
}
]
}
}
}
]
}
},
{
"type": "ObjectExpression",
"properties": [
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "types"
},
"kind": "init",
"value": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Set"
},
"arguments": [
{
"type": "ArrayExpression",
"elements": [
{
"type": "Literal",
"value": "ion.ast.Node"
}
]
}
]
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "is"
},
"kind": "init",
"value": {
"type": "Literal",
"value": "$ => $ != null && $.constructor.types != null && $.constructor.types.has('ion.ast.Node')",
"verbatim": "$ => $ != null && $.constructor.types != null && $.constructor.types.has('ion.ast.Node')"
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "path"
},
"kind": "init",
"value": {
"type": "Literal",
"value": "ion.ast.Node"
}
}
]
}
]
}
]
}
}
]
},
{
"type": "VariableDeclaration",
"kind": "const",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "ion_ast_Declaration"
},
"init": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "freeze"
}
},
"arguments": [
{
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "assign"
}
},
"arguments": [
{
"type": "ClassExpression",
"id": {
"type": "Identifier",
"name": "Declaration"
},
"superClass": null,
"body": {
"type": "ClassBody",
"body": [
{
"type": "MethodDefinition",
"kind": "constructor",
"key": {
"type": "Identifier",
"name": "constructor"
},
"value": {
"type": "FunctionExpression",
"id": null,
"params": [],
"body": {
"type": "BlockStatement",
"body": [
{
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "Literal",
"value": "Declaration is abstract"
}
]
}
}
]
}
}
}
]
}
},
{
"type": "ObjectExpression",
"properties": [
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "types"
},
"kind": "init",
"value": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Set"
},
"arguments": [
{
"type": "ArrayExpression",
"elements": [
{
"type": "Literal",
"value": "ion.ast.Node"
},
{
"type": "Literal",
"value": "ion.ast.Declaration"
}
]
}
]
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "is"
},
"kind": "init",
"value": {
"type": "Literal",
"value": "$ => $ != null && $.constructor.types != null && $.constructor.types.has('ion.ast.Declaration')",
"verbatim": "$ => $ != null && $.constructor.types != null && $.constructor.types.has('ion.ast.Declaration')"
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "path"
},
"kind": "init",
"value": {
"type": "Literal",
"value": "ion.ast.Declaration"
}
}
]
}
]
}
]
}
}
]
},
{
"type": "VariableDeclaration",
"kind": "const",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "ion_ast_ClassDeclaration"
},
"init": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "freeze"
}
},
"arguments": [
{
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "assign"
}
},
"arguments": [
{
"type": "ClassExpression",
"id": {
"type": "Identifier",
"name": "ClassDeclaration"
},
"superClass": null,
"body": {
"type": "ClassBody",
"body": [
{
"type": "MethodDefinition",
"kind": "constructor",
"key": {
"type": "Identifier",
"name": "constructor"
},
"value": {
"type": "FunctionExpression",
"id": null,
"params": [
{
"type": "RestElement",
"argument": {
"type": "Identifier",
"name": "args"
}
}
],
"body": {
"type": "BlockStatement",
"body": [
{
"type": "VariableDeclaration",
"kind": "let",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "location"
},
"init": null
},
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "id"
},
"init": null
},
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "isStructure"
},
"init": {
"type": "Literal",
"value": false
}
},
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "isAbstract"
},
"init": {
"type": "Literal",
"value": false
}
},
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "templateParameters"
},
"init": null
},
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "baseClasses"
},
"init": null
},
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "declarations"
},
"init": null
},
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "meta"
},
"init": null
}
]
},
{
"type": "ForOfStatement",
"left": {
"type": "VariableDeclaration",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "arg"
}
}
],
"kind": "let"
},
"right": {
"type": "Identifier",
"name": "args"
},
"body": {
"type": "BlockStatement",
"body": [
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!=",
"left": {
"type": "Identifier",
"name": "arg"
},
"right": {
"type": "Literal",
"value": null
}
},
"consequent": {
"type": "BlockStatement",
"body": [
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!==",
"left": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"type": "Identifier",
"name": "location"
}
},
"right": {
"type": "Identifier",
"name": "undefined"
}
},
"consequent": {
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "Identifier",
"name": "location"
},
"right": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.0.test.left.property"
}
}
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!==",
"left": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"type": "Identifier",
"name": "id"
}
},
"right": {
"type": "Identifier",
"name": "undefined"
}
},
"consequent": {
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "Identifier",
"name": "id"
},
"right": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.1.test.left.property"
}
}
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!==",
"left": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"type": "Identifier",
"name": "isStructure"
}
},
"right": {
"type": "Identifier",
"name": "undefined"
}
},
"consequent": {
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "Identifier",
"name": "isStructure"
},
"right": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.2.test.left.property"
}
}
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!==",
"left": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"type": "Identifier",
"name": "isAbstract"
}
},
"right": {
"type": "Identifier",
"name": "undefined"
}
},
"consequent": {
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "Identifier",
"name": "isAbstract"
},
"right": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.3.test.left.property"
}
}
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!==",
"left": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"type": "Identifier",
"name": "templateParameters"
}
},
"right": {
"type": "Identifier",
"name": "undefined"
}
},
"consequent": {
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "Identifier",
"name": "templateParameters"
},
"right": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.4.test.left.property"
}
}
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!==",
"left": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"type": "Identifier",
"name": "baseClasses"
}
},
"right": {
"type": "Identifier",
"name": "undefined"
}
},
"consequent": {
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "Identifier",
"name": "baseClasses"
},
"right": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.5.test.left.property"
}
}
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!==",
"left": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"type": "Identifier",
"name": "declarations"
}
},
"right": {
"type": "Identifier",
"name": "undefined"
}
},
"consequent": {
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "Identifier",
"name": "declarations"
},
"right": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.6.test.left.property"
}
}
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!==",
"left": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"type": "Identifier",
"name": "meta"
}
},
"right": {
"type": "Identifier",
"name": "undefined"
}
},
"consequent": {
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "Identifier",
"name": "meta"
},
"right": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.7.test.left.property"
}
}
}
},
"alternate": null
}
]
},
"alternate": null
}
]
}
},
{
"type": "IfStatement",
"test": {
"type": "UnaryExpression",
"operator": "!",
"argument": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "ion_ast_Location"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "location"
}
]
}
},
"consequent": {
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "BinaryExpression",
"left": {
"type": "Literal",
"value": "location is not valid: "
},
"operator": "+",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "JSON"
},
"property": {
"type": "Identifier",
"name": "stringify"
}
},
"arguments": [
{
"type": "Identifier",
"name": "location"
}
]
}
}
]
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "UnaryExpression",
"operator": "!",
"argument": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "ion_ast_Id"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "id"
}
]
}
},
"consequent": {
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "BinaryExpression",
"left": {
"type": "Literal",
"value": "id is not valid: "
},
"operator": "+",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "JSON"
},
"property": {
"type": "Identifier",
"name": "stringify"
}
},
"arguments": [
{
"type": "Identifier",
"name": "id"
}
]
}
}
]
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "UnaryExpression",
"operator": "!",
"argument": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "ion_Boolean"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "isStructure"
}
]
}
},
"consequent": {
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "BinaryExpression",
"left": {
"type": "Literal",
"value": "isStructure is not valid: "
},
"operator": "+",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "JSON"
},
"property": {
"type": "Identifier",
"name": "stringify"
}
},
"arguments": [
{
"type": "Identifier",
"name": "isStructure"
}
]
}
}
]
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "UnaryExpression",
"operator": "!",
"argument": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "ion_Boolean"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "isAbstract"
}
]
}
},
"consequent": {
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "BinaryExpression",
"left": {
"type": "Literal",
"value": "isAbstract is not valid: "
},
"operator": "+",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "JSON"
},
"property": {
"type": "Identifier",
"name": "stringify"
}
},
"arguments": [
{
"type": "Identifier",
"name": "isAbstract"
}
]
}
}
]
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "UnaryExpression",
"operator": "!",
"argument": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "ion_Array"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "templateParameters"
},
{
"type": "Identifier",
"name": "ion_ast_Parameter"
}
]
}
},
"consequent": {
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "BinaryExpression",
"left": {
"type": "Literal",
"value": "templateParameters is not valid: "
},
"operator": "+",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "JSON"
},
"property": {
"type": "Identifier",
"name": "stringify"
}
},
"arguments": [
{
"type": "Identifier",
"name": "templateParameters"
}
]
}
}
]
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "UnaryExpression",
"operator": "!",
"argument": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "ion_Array"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "baseClasses"
},
{
"type": "Identifier",
"name": "ion_ast_Reference"
}
]
}
},
"consequent": {
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "BinaryExpression",
"left": {
"type": "Literal",
"value": "baseClasses is not valid: "
},
"operator": "+",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "JSON"
},
"property": {
"type": "Identifier",
"name": "stringify"
}
},
"arguments": [
{
"type": "Identifier",
"name": "baseClasses"
}
]
}
}
]
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "UnaryExpression",
"operator": "!",
"argument": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "ion_Array"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "declarations"
},
{
"type": "Identifier",
"name": "ion_ast_Declaration"
}
]
}
},
"consequent": {
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "BinaryExpression",
"left": {
"type": "Literal",
"value": "declarations is not valid: "
},
"operator": "+",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "JSON"
},
"property": {
"type": "Identifier",
"name": "stringify"
}
},
"arguments": [
{
"type": "Identifier",
"name": "declarations"
}
]
}
}
]
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "UnaryExpression",
"operator": "!",
"argument": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "ion_Array"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "meta"
},
{
"type": "Identifier",
"name": "ion_ast_Property"
}
]
}
},
"consequent": {
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "BinaryExpression",
"left": {
"type": "Literal",
"value": "meta is not valid: "
},
"operator": "+",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "JSON"
},
"property": {
"type": "Identifier",
"name": "stringify"
}
},
"arguments": [
{
"type": "Identifier",
"name": "meta"
}
]
}
}
]
}
},
"alternate": null
},
{
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "MemberExpression",
"object": {
"type": "ThisExpression"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.0.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "location"
}
}
},
{
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "MemberExpression",
"object": {
"type": "ThisExpression"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.1.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "id"
}
}
},
{
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "MemberExpression",
"object": {
"type": "ThisExpression"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.2.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "isStructure"
}
}
},
{
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "MemberExpression",
"object": {
"type": "ThisExpression"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.3.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "isAbstract"
}
}
},
{
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "MemberExpression",
"object": {
"type": "ThisExpression"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.4.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "templateParameters"
}
}
},
{
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "MemberExpression",
"object": {
"type": "ThisExpression"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.5.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "baseClasses"
}
}
},
{
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "MemberExpression",
"object": {
"type": "ThisExpression"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.6.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "declarations"
}
}
},
{
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "MemberExpression",
"object": {
"type": "ThisExpression"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.7.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "meta"
}
}
},
{
"type": "ExpressionStatement",
"expression": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "freeze"
}
},
"arguments": [
{
"type": "ThisExpression"
}
]
}
}
]
}
}
}
]
}
},
{
"type": "ObjectExpression",
"properties": [
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "types"
},
"kind": "init",
"value": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Set"
},
"arguments": [
{
"type": "ArrayExpression",
"elements": [
{
"type": "Literal",
"value": "ion.ast.Declaration"
},
{
"type": "Literal",
"value": "ion.ast.Node"
},
{
"type": "Literal",
"value": "ion.ast.ClassDeclaration"
}
]
}
]
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "is"
},
"kind": "init",
"value": {
"type": "Literal",
"value": "$ => $ != null && $.constructor.types != null && $.constructor.types.has('ion.ast.ClassDeclaration')",
"verbatim": "$ => $ != null && $.constructor.types != null && $.constructor.types.has('ion.ast.ClassDeclaration')"
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "path"
},
"kind": "init",
"value": {
"type": "Literal",
"value": "ion.ast.ClassDeclaration"
}
}
]
}
]
}
]
}
}
]
},
{
"type": "VariableDeclaration",
"kind": "const",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "ion_ast_Expression"
},
"init": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "freeze"
}
},
"arguments": [
{
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "assign"
}
},
"arguments": [
{
"type": "ClassExpression",
"id": {
"type": "Identifier",
"name": "Expression"
},
"superClass": null,
"body": {
"type": "ClassBody",
"body": [
{
"type": "MethodDefinition",
"kind": "constructor",
"key": {
"type": "Identifier",
"name": "constructor"
},
"value": {
"type": "FunctionExpression",
"id": null,
"params": [],
"body": {
"type": "BlockStatement",
"body": [
{
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "Literal",
"value": "Expression is abstract"
}
]
}
}
]
}
}
}
]
}
},
{
"type": "ObjectExpression",
"properties": [
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "types"
},
"kind": "init",
"value": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Set"
},
"arguments": [
{
"type": "ArrayExpression",
"elements": [
{
"type": "Literal",
"value": "ion.ast.Node"
},
{
"type": "Literal",
"value": "ion.ast.Expression"
}
]
}
]
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "is"
},
"kind": "init",
"value": {
"type": "Literal",
"value": "$ => $ != null && $.constructor.types != null && $.constructor.types.has('ion.ast.Expression')",
"verbatim": "$ => $ != null && $.constructor.types != null && $.constructor.types.has('ion.ast.Expression')"
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "path"
},
"kind": "init",
"value": {
"type": "Literal",
"value": "ion.ast.Expression"
}
}
]
}
]
}
]
}
}
]
},
{
"type": "VariableDeclaration",
"kind": "const",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "ion_ast_Argument"
},
"init": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "freeze"
}
},
"arguments": [
{
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "assign"
}
},
"arguments": [
{
"type": "ClassExpression",
"id": {
"type": "Identifier",
"name": "Argument"
},
"superClass": null,
"body": {
"type": "ClassBody",
"body": [
{
"type": "MethodDefinition",
"kind": "constructor",
"key": {
"type": "Identifier",
"name": "constructor"
},
"value": {
"type": "FunctionExpression",
"id": null,
"params": [
{
"type": "RestElement",
"argument": {
"type": "Identifier",
"name": "args"
}
}
],
"body": {
"type": "BlockStatement",
"body": [
{
"type": "VariableDeclaration",
"kind": "let",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "location"
},
"init": null
},
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "id"
},
"init": {
"type": "Literal",
"value": null
}
},
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "value"
},
"init": null
}
]
},
{
"type": "ForOfStatement",
"left": {
"type": "VariableDeclaration",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "arg"
}
}
],
"kind": "let"
},
"right": {
"type": "Identifier",
"name": "args"
},
"body": {
"type": "BlockStatement",
"body": [
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!=",
"left": {
"type": "Identifier",
"name": "arg"
},
"right": {
"type": "Literal",
"value": null
}
},
"consequent": {
"type": "BlockStatement",
"body": [
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!==",
"left": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.0.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "undefined"
}
},
"consequent": {
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "Identifier",
"name": "location"
},
"right": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.0.test.left.property"
}
}
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!==",
"left": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"type": "Identifier",
"name": "id"
}
},
"right": {
"type": "Identifier",
"name": "undefined"
}
},
"consequent": {
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "Identifier",
"name": "id"
},
"right": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.7.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.1.test.left.property"
}
}
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!==",
"left": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"type": "Identifier",
"name": "value"
}
},
"right": {
"type": "Identifier",
"name": "undefined"
}
},
"consequent": {
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "Identifier",
"name": "value"
},
"right": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.7.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.2.test.left.property"
}
}
}
},
"alternate": null
}
]
},
"alternate": null
}
]
}
},
{
"type": "IfStatement",
"test": {
"type": "UnaryExpression",
"operator": "!",
"argument": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.2.test.argument.callee.object"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "location"
}
]
}
},
"consequent": {
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "BinaryExpression",
"left": {
"type": "Literal",
"value": "location is not valid: "
},
"operator": "+",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "JSON"
},
"property": {
"type": "Identifier",
"name": "stringify"
}
},
"arguments": [
{
"type": "Identifier",
"name": "location"
}
]
}
}
]
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "UnaryExpression",
"operator": "!",
"argument": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "ObjectExpression",
"properties": [
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "is"
},
"kind": "init",
"value": {
"type": "ArrowFunctionExpression",
"id": null,
"params": [
{
"type": "Identifier",
"name": "$"
}
],
"expression": true,
"body": {
"type": "BinaryExpression",
"left": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "ion_ast_Id"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "$"
}
]
},
"operator": "||",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "ion_Null"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "$"
}
]
}
}
}
}
]
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "id"
}
]
}
},
"consequent": {
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "BinaryExpression",
"left": {
"type": "Literal",
"value": "id is not valid: "
},
"operator": "+",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "JSON"
},
"property": {
"type": "Identifier",
"name": "stringify"
}
},
"arguments": [
{
"type": "Identifier",
"name": "id"
}
]
}
}
]
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "UnaryExpression",
"operator": "!",
"argument": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "ion_ast_Expression"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "value"
}
]
}
},
"consequent": {
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "BinaryExpression",
"left": {
"type": "Literal",
"value": "value is not valid: "
},
"operator": "+",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "JSON"
},
"property": {
"type": "Identifier",
"name": "stringify"
}
},
"arguments": [
{
"type": "Identifier",
"name": "value"
}
]
}
}
]
}
},
"alternate": null
},
{
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "MemberExpression",
"object": {
"type": "ThisExpression"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.0.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "location"
}
}
},
{
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "MemberExpression",
"object": {
"type": "ThisExpression"
},
"property": {
"$ref": "body.7.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.1.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "id"
}
}
},
{
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "MemberExpression",
"object": {
"type": "ThisExpression"
},
"property": {
"$ref": "body.7.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.2.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "value"
}
}
},
{
"type": "ExpressionStatement",
"expression": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "freeze"
}
},
"arguments": [
{
"type": "ThisExpression"
}
]
}
}
]
}
}
}
]
}
},
{
"type": "ObjectExpression",
"properties": [
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "types"
},
"kind": "init",
"value": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Set"
},
"arguments": [
{
"type": "ArrayExpression",
"elements": [
{
"type": "Literal",
"value": "ion.ast.Expression"
},
{
"type": "Literal",
"value": "ion.ast.Node"
},
{
"type": "Literal",
"value": "ion.ast.Argument"
}
]
}
]
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "is"
},
"kind": "init",
"value": {
"type": "Literal",
"value": "$ => $ != null && $.constructor.types != null && $.constructor.types.has('ion.ast.Argument')",
"verbatim": "$ => $ != null && $.constructor.types != null && $.constructor.types.has('ion.ast.Argument')"
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "path"
},
"kind": "init",
"value": {
"type": "Literal",
"value": "ion.ast.Argument"
}
}
]
}
]
}
]
}
}
]
},
{
"type": "VariableDeclaration",
"kind": "const",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "ion_ast_CallExpression"
},
"init": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "freeze"
}
},
"arguments": [
{
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "assign"
}
},
"arguments": [
{
"type": "ClassExpression",
"id": {
"type": "Identifier",
"name": "CallExpression"
},
"superClass": null,
"body": {
"type": "ClassBody",
"body": [
{
"type": "MethodDefinition",
"kind": "constructor",
"key": {
"type": "Identifier",
"name": "constructor"
},
"value": {
"type": "FunctionExpression",
"id": null,
"params": [
{
"type": "RestElement",
"argument": {
"type": "Identifier",
"name": "args"
}
}
],
"body": {
"type": "BlockStatement",
"body": [
{
"type": "VariableDeclaration",
"kind": "let",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "location"
},
"init": null
},
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "callee"
},
"init": null
},
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "$arguments"
},
"init": null
}
]
},
{
"type": "ForOfStatement",
"left": {
"type": "VariableDeclaration",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "arg"
}
}
],
"kind": "let"
},
"right": {
"type": "Identifier",
"name": "args"
},
"body": {
"type": "BlockStatement",
"body": [
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!=",
"left": {
"type": "Identifier",
"name": "arg"
},
"right": {
"type": "Literal",
"value": null
}
},
"consequent": {
"type": "BlockStatement",
"body": [
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!==",
"left": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.0.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "undefined"
}
},
"consequent": {
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "Identifier",
"name": "location"
},
"right": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.0.test.left.property"
}
}
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!==",
"left": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"type": "Identifier",
"name": "callee"
}
},
"right": {
"type": "Identifier",
"name": "undefined"
}
},
"consequent": {
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "Identifier",
"name": "callee"
},
"right": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.8.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.1.test.left.property"
}
}
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!==",
"left": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"type": "Identifier",
"name": "arguments"
}
},
"right": {
"type": "Identifier",
"name": "undefined"
}
},
"consequent": {
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "Identifier",
"name": "$arguments"
},
"right": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.8.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.2.test.left.property"
}
}
}
},
"alternate": null
}
]
},
"alternate": null
}
]
}
},
{
"type": "IfStatement",
"test": {
"type": "UnaryExpression",
"operator": "!",
"argument": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.2.test.argument.callee.object"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "location"
}
]
}
},
"consequent": {
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "BinaryExpression",
"left": {
"type": "Literal",
"value": "location is not valid: "
},
"operator": "+",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "JSON"
},
"property": {
"type": "Identifier",
"name": "stringify"
}
},
"arguments": [
{
"type": "Identifier",
"name": "location"
}
]
}
}
]
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "UnaryExpression",
"operator": "!",
"argument": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "ion_ast_Expression"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "callee"
}
]
}
},
"consequent": {
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "BinaryExpression",
"left": {
"type": "Literal",
"value": "callee is not valid: "
},
"operator": "+",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "JSON"
},
"property": {
"type": "Identifier",
"name": "stringify"
}
},
"arguments": [
{
"type": "Identifier",
"name": "callee"
}
]
}
}
]
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "UnaryExpression",
"operator": "!",
"argument": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "ion_Array"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "$arguments"
},
{
"type": "Identifier",
"name": "ion_ast_Argument"
}
]
}
},
"consequent": {
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "BinaryExpression",
"left": {
"type": "Literal",
"value": "$arguments is not valid: "
},
"operator": "+",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "JSON"
},
"property": {
"type": "Identifier",
"name": "stringify"
}
},
"arguments": [
{
"type": "Identifier",
"name": "$arguments"
}
]
}
}
]
}
},
"alternate": null
},
{
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "MemberExpression",
"object": {
"type": "ThisExpression"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.0.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "location"
}
}
},
{
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "MemberExpression",
"object": {
"type": "ThisExpression"
},
"property": {
"$ref": "body.8.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.1.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "callee"
}
}
},
{
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "MemberExpression",
"object": {
"type": "ThisExpression"
},
"property": {
"$ref": "body.8.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.2.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "$arguments"
}
}
},
{
"type": "ExpressionStatement",
"expression": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "freeze"
}
},
"arguments": [
{
"type": "ThisExpression"
}
]
}
}
]
}
}
}
]
}
},
{
"type": "ObjectExpression",
"properties": [
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "types"
},
"kind": "init",
"value": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Set"
},
"arguments": [
{
"type": "ArrayExpression",
"elements": [
{
"type": "Literal",
"value": "ion.ast.Expression"
},
{
"type": "Literal",
"value": "ion.ast.Node"
},
{
"type": "Literal",
"value": "ion.ast.CallExpression"
}
]
}
]
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "is"
},
"kind": "init",
"value": {
"type": "Literal",
"value": "$ => $ != null && $.constructor.types != null && $.constructor.types.has('ion.ast.CallExpression')",
"verbatim": "$ => $ != null && $.constructor.types != null && $.constructor.types.has('ion.ast.CallExpression')"
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "path"
},
"kind": "init",
"value": {
"type": "Literal",
"value": "ion.ast.CallExpression"
}
}
]
}
]
}
]
}
}
]
},
{
"type": "VariableDeclaration",
"kind": "const",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "ion_ast_DotExpression"
},
"init": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "freeze"
}
},
"arguments": [
{
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "assign"
}
},
"arguments": [
{
"type": "ClassExpression",
"id": {
"type": "Identifier",
"name": "DotExpression"
},
"superClass": null,
"body": {
"type": "ClassBody",
"body": [
{
"type": "MethodDefinition",
"kind": "constructor",
"key": {
"type": "Identifier",
"name": "constructor"
},
"value": {
"type": "FunctionExpression",
"id": null,
"params": [
{
"type": "RestElement",
"argument": {
"type": "Identifier",
"name": "args"
}
}
],
"body": {
"type": "BlockStatement",
"body": [
{
"type": "VariableDeclaration",
"kind": "let",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "location"
},
"init": null
}
]
},
{
"type": "ForOfStatement",
"left": {
"type": "VariableDeclaration",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "arg"
}
}
],
"kind": "let"
},
"right": {
"type": "Identifier",
"name": "args"
},
"body": {
"type": "BlockStatement",
"body": [
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!=",
"left": {
"type": "Identifier",
"name": "arg"
},
"right": {
"type": "Literal",
"value": null
}
},
"consequent": {
"type": "BlockStatement",
"body": [
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!==",
"left": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.0.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "undefined"
}
},
"consequent": {
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "Identifier",
"name": "location"
},
"right": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.0.test.left.property"
}
}
}
},
"alternate": null
}
]
},
"alternate": null
}
]
}
},
{
"type": "IfStatement",
"test": {
"type": "UnaryExpression",
"operator": "!",
"argument": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.2.test.argument.callee.object"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "location"
}
]
}
},
"consequent": {
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "BinaryExpression",
"left": {
"type": "Literal",
"value": "location is not valid: "
},
"operator": "+",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "JSON"
},
"property": {
"type": "Identifier",
"name": "stringify"
}
},
"arguments": [
{
"type": "Identifier",
"name": "location"
}
]
}
}
]
}
},
"alternate": null
},
{
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "MemberExpression",
"object": {
"type": "ThisExpression"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.0.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "location"
}
}
},
{
"type": "ExpressionStatement",
"expression": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "freeze"
}
},
"arguments": [
{
"type": "ThisExpression"
}
]
}
}
]
}
}
}
]
}
},
{
"type": "ObjectExpression",
"properties": [
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "types"
},
"kind": "init",
"value": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Set"
},
"arguments": [
{
"type": "ArrayExpression",
"elements": [
{
"type": "Literal",
"value": "ion.ast.Expression"
},
{
"type": "Literal",
"value": "ion.ast.Node"
},
{
"type": "Literal",
"value": "ion.ast.DotExpression"
}
]
}
]
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "is"
},
"kind": "init",
"value": {
"type": "Literal",
"value": "$ => $ != null && $.constructor.types != null && $.constructor.types.has('ion.ast.DotExpression')",
"verbatim": "$ => $ != null && $.constructor.types != null && $.constructor.types.has('ion.ast.DotExpression')"
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "path"
},
"kind": "init",
"value": {
"type": "Literal",
"value": "ion.ast.DotExpression"
}
}
]
}
]
}
]
}
}
]
},
{
"type": "VariableDeclaration",
"kind": "const",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "ion_String"
},
"init": {
"type": "Literal",
"value": "Object.freeze({
is(value) {
return typeof value === 'string'
},
length(value) {
return value.length
},
trimmed(value) {
return value.trim()
}
})",
"verbatim": "Object.freeze({
is(value) {
return typeof value === 'string'
},
length(value) {
return value.length
},
trimmed(value) {
return value.trim()
}
})"
}
}
]
},
{
"type": "VariableDeclaration",
"kind": "const",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "ion_ast_Id"
},
"init": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "freeze"
}
},
"arguments": [
{
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "assign"
}
},
"arguments": [
{
"type": "ClassExpression",
"id": {
"type": "Identifier",
"name": "Id"
},
"superClass": null,
"body": {
"type": "ClassBody",
"body": [
{
"type": "MethodDefinition",
"kind": "constructor",
"key": {
"type": "Identifier",
"name": "constructor"
},
"value": {
"type": "FunctionExpression",
"id": null,
"params": [
{
"type": "RestElement",
"argument": {
"type": "Identifier",
"name": "args"
}
}
],
"body": {
"type": "BlockStatement",
"body": [
{
"type": "VariableDeclaration",
"kind": "let",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "location"
},
"init": null
},
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "name"
},
"init": null
}
]
},
{
"type": "ForOfStatement",
"left": {
"type": "VariableDeclaration",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "arg"
}
}
],
"kind": "let"
},
"right": {
"type": "Identifier",
"name": "args"
},
"body": {
"type": "BlockStatement",
"body": [
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!=",
"left": {
"type": "Identifier",
"name": "arg"
},
"right": {
"type": "Literal",
"value": null
}
},
"consequent": {
"type": "BlockStatement",
"body": [
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!==",
"left": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.0.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "undefined"
}
},
"consequent": {
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "Identifier",
"name": "location"
},
"right": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.0.test.left.property"
}
}
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!==",
"left": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"type": "Identifier",
"name": "name"
}
},
"right": {
"type": "Identifier",
"name": "undefined"
}
},
"consequent": {
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "Identifier",
"name": "name"
},
"right": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.11.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.1.test.left.property"
}
}
}
},
"alternate": null
}
]
},
"alternate": null
}
]
}
},
{
"type": "IfStatement",
"test": {
"type": "UnaryExpression",
"operator": "!",
"argument": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.2.test.argument.callee.object"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "location"
}
]
}
},
"consequent": {
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "BinaryExpression",
"left": {
"type": "Literal",
"value": "location is not valid: "
},
"operator": "+",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "JSON"
},
"property": {
"type": "Identifier",
"name": "stringify"
}
},
"arguments": [
{
"type": "Identifier",
"name": "location"
}
]
}
}
]
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "UnaryExpression",
"operator": "!",
"argument": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "ion_String"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "name"
}
]
}
},
"consequent": {
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "BinaryExpression",
"left": {
"type": "Literal",
"value": "name is not valid: "
},
"operator": "+",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "JSON"
},
"property": {
"type": "Identifier",
"name": "stringify"
}
},
"arguments": [
{
"type": "Identifier",
"name": "name"
}
]
}
}
]
}
},
"alternate": null
},
{
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "MemberExpression",
"object": {
"type": "ThisExpression"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.0.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "location"
}
}
},
{
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "MemberExpression",
"object": {
"type": "ThisExpression"
},
"property": {
"$ref": "body.11.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.1.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "name"
}
}
},
{
"type": "ExpressionStatement",
"expression": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "freeze"
}
},
"arguments": [
{
"type": "ThisExpression"
}
]
}
}
]
}
}
}
]
}
},
{
"type": "ObjectExpression",
"properties": [
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "types"
},
"kind": "init",
"value": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Set"
},
"arguments": [
{
"type": "ArrayExpression",
"elements": [
{
"type": "Literal",
"value": "ion.ast.Expression"
},
{
"type": "Literal",
"value": "ion.ast.Node"
},
{
"type": "Literal",
"value": "ion.ast.Id"
}
]
}
]
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "is"
},
"kind": "init",
"value": {
"type": "Literal",
"value": "$ => $ != null && $.constructor.types != null && $.constructor.types.has('ion.ast.Id')",
"verbatim": "$ => $ != null && $.constructor.types != null && $.constructor.types.has('ion.ast.Id')"
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "path"
},
"kind": "init",
"value": {
"type": "Literal",
"value": "ion.ast.Id"
}
}
]
}
]
}
]
}
}
]
},
{
"type": "VariableDeclaration",
"kind": "const",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "ion_ast_ImportStep"
},
"init": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "freeze"
}
},
"arguments": [
{
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "assign"
}
},
"arguments": [
{
"type": "ClassExpression",
"id": {
"type": "Identifier",
"name": "ImportStep"
},
"superClass": null,
"body": {
"type": "ClassBody",
"body": [
{
"type": "MethodDefinition",
"kind": "constructor",
"key": {
"type": "Identifier",
"name": "constructor"
},
"value": {
"type": "FunctionExpression",
"id": null,
"params": [
{
"type": "RestElement",
"argument": {
"type": "Identifier",
"name": "args"
}
}
],
"body": {
"type": "BlockStatement",
"body": [
{
"type": "VariableDeclaration",
"kind": "let",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "location"
},
"init": null
},
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "relative"
},
"init": {
"type": "Literal",
"value": false
}
},
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "name"
},
"init": {
"type": "Literal",
"value": null
}
},
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "as"
},
"init": {
"type": "Literal",
"value": null
}
},
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "children"
},
"init": null
}
]
},
{
"type": "ForOfStatement",
"left": {
"type": "VariableDeclaration",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "arg"
}
}
],
"kind": "let"
},
"right": {
"type": "Identifier",
"name": "args"
},
"body": {
"type": "BlockStatement",
"body": [
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!=",
"left": {
"type": "Identifier",
"name": "arg"
},
"right": {
"type": "Literal",
"value": null
}
},
"consequent": {
"type": "BlockStatement",
"body": [
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!==",
"left": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.0.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "undefined"
}
},
"consequent": {
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "Identifier",
"name": "location"
},
"right": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.0.test.left.property"
}
}
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!==",
"left": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"type": "Identifier",
"name": "relative"
}
},
"right": {
"type": "Identifier",
"name": "undefined"
}
},
"consequent": {
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "Identifier",
"name": "relative"
},
"right": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.12.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.1.test.left.property"
}
}
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!==",
"left": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"type": "Identifier",
"name": "name"
}
},
"right": {
"type": "Identifier",
"name": "undefined"
}
},
"consequent": {
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "Identifier",
"name": "name"
},
"right": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.12.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.2.test.left.property"
}
}
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!==",
"left": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"type": "Identifier",
"name": "as"
}
},
"right": {
"type": "Identifier",
"name": "undefined"
}
},
"consequent": {
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "Identifier",
"name": "as"
},
"right": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.12.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.3.test.left.property"
}
}
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!==",
"left": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"type": "Identifier",
"name": "children"
}
},
"right": {
"type": "Identifier",
"name": "undefined"
}
},
"consequent": {
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "Identifier",
"name": "children"
},
"right": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.12.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.4.test.left.property"
}
}
}
},
"alternate": null
}
]
},
"alternate": null
}
]
}
},
{
"type": "IfStatement",
"test": {
"type": "UnaryExpression",
"operator": "!",
"argument": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.2.test.argument.callee.object"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "location"
}
]
}
},
"consequent": {
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "BinaryExpression",
"left": {
"type": "Literal",
"value": "location is not valid: "
},
"operator": "+",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "JSON"
},
"property": {
"type": "Identifier",
"name": "stringify"
}
},
"arguments": [
{
"type": "Identifier",
"name": "location"
}
]
}
}
]
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "UnaryExpression",
"operator": "!",
"argument": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "ion_Boolean"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "relative"
}
]
}
},
"consequent": {
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "BinaryExpression",
"left": {
"type": "Literal",
"value": "relative is not valid: "
},
"operator": "+",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "JSON"
},
"property": {
"type": "Identifier",
"name": "stringify"
}
},
"arguments": [
{
"type": "Identifier",
"name": "relative"
}
]
}
}
]
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "UnaryExpression",
"operator": "!",
"argument": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "ObjectExpression",
"properties": [
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "is"
},
"kind": "init",
"value": {
"type": "ArrowFunctionExpression",
"id": null,
"params": [
{
"type": "Identifier",
"name": "$"
}
],
"expression": true,
"body": {
"type": "BinaryExpression",
"left": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "ion_ast_Id"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "$"
}
]
},
"operator": "||",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "ion_Null"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "$"
}
]
}
}
}
}
]
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "name"
}
]
}
},
"consequent": {
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "BinaryExpression",
"left": {
"type": "Literal",
"value": "name is not valid: "
},
"operator": "+",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "JSON"
},
"property": {
"type": "Identifier",
"name": "stringify"
}
},
"arguments": [
{
"type": "Identifier",
"name": "name"
}
]
}
}
]
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "UnaryExpression",
"operator": "!",
"argument": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "ObjectExpression",
"properties": [
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "is"
},
"kind": "init",
"value": {
"type": "ArrowFunctionExpression",
"id": null,
"params": [
{
"type": "Identifier",
"name": "$"
}
],
"expression": true,
"body": {
"type": "BinaryExpression",
"left": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "ion_ast_Id"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "$"
}
]
},
"operator": "||",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "ion_Null"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "$"
}
]
}
}
}
}
]
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "as"
}
]
}
},
"consequent": {
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "BinaryExpression",
"left": {
"type": "Literal",
"value": "as is not valid: "
},
"operator": "+",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "JSON"
},
"property": {
"type": "Identifier",
"name": "stringify"
}
},
"arguments": [
{
"type": "Identifier",
"name": "as"
}
]
}
}
]
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "UnaryExpression",
"operator": "!",
"argument": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "ion_Array"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "children"
},
{
"type": "Identifier",
"name": "ion_ast_ImportStep"
}
]
}
},
"consequent": {
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "BinaryExpression",
"left": {
"type": "Literal",
"value": "children is not valid: "
},
"operator": "+",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "JSON"
},
"property": {
"type": "Identifier",
"name": "stringify"
}
},
"arguments": [
{
"type": "Identifier",
"name": "children"
}
]
}
}
]
}
},
"alternate": null
},
{
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "MemberExpression",
"object": {
"type": "ThisExpression"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.0.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "location"
}
}
},
{
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "MemberExpression",
"object": {
"type": "ThisExpression"
},
"property": {
"$ref": "body.12.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.1.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "relative"
}
}
},
{
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "MemberExpression",
"object": {
"type": "ThisExpression"
},
"property": {
"$ref": "body.12.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.2.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "name"
}
}
},
{
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "MemberExpression",
"object": {
"type": "ThisExpression"
},
"property": {
"$ref": "body.12.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.3.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "as"
}
}
},
{
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "MemberExpression",
"object": {
"type": "ThisExpression"
},
"property": {
"$ref": "body.12.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.4.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "children"
}
}
},
{
"type": "ExpressionStatement",
"expression": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "freeze"
}
},
"arguments": [
{
"type": "ThisExpression"
}
]
}
}
]
}
}
}
]
}
},
{
"type": "ObjectExpression",
"properties": [
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "types"
},
"kind": "init",
"value": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Set"
},
"arguments": [
{
"type": "ArrayExpression",
"elements": [
{
"type": "Literal",
"value": "ion.ast.Node"
},
{
"type": "Literal",
"value": "ion.ast.ImportStep"
}
]
}
]
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "is"
},
"kind": "init",
"value": {
"type": "Literal",
"value": "$ => $ != null && $.constructor.types != null && $.constructor.types.has('ion.ast.ImportStep')",
"verbatim": "$ => $ != null && $.constructor.types != null && $.constructor.types.has('ion.ast.ImportStep')"
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "path"
},
"kind": "init",
"value": {
"type": "Literal",
"value": "ion.ast.ImportStep"
}
}
]
}
]
}
]
}
}
]
},
{
"type": "VariableDeclaration",
"kind": "const",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "ion_ast_Literal"
},
"init": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "freeze"
}
},
"arguments": [
{
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "assign"
}
},
"arguments": [
{
"type": "ClassExpression",
"id": {
"type": "Identifier",
"name": "Literal"
},
"superClass": null,
"body": {
"type": "ClassBody",
"body": [
{
"type": "MethodDefinition",
"kind": "constructor",
"key": {
"type": "Identifier",
"name": "constructor"
},
"value": {
"type": "FunctionExpression",
"id": null,
"params": [
{
"type": "RestElement",
"argument": {
"type": "Identifier",
"name": "args"
}
}
],
"body": {
"type": "BlockStatement",
"body": [
{
"type": "VariableDeclaration",
"kind": "let",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "location"
},
"init": null
},
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "value"
},
"init": null
}
]
},
{
"type": "ForOfStatement",
"left": {
"type": "VariableDeclaration",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "arg"
}
}
],
"kind": "let"
},
"right": {
"type": "Identifier",
"name": "args"
},
"body": {
"type": "BlockStatement",
"body": [
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!=",
"left": {
"type": "Identifier",
"name": "arg"
},
"right": {
"type": "Literal",
"value": null
}
},
"consequent": {
"type": "BlockStatement",
"body": [
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!==",
"left": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.0.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "undefined"
}
},
"consequent": {
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "Identifier",
"name": "location"
},
"right": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.0.test.left.property"
}
}
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!==",
"left": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"type": "Identifier",
"name": "value"
}
},
"right": {
"type": "Identifier",
"name": "undefined"
}
},
"consequent": {
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "Identifier",
"name": "value"
},
"right": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.13.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.1.test.left.property"
}
}
}
},
"alternate": null
}
]
},
"alternate": null
}
]
}
},
{
"type": "IfStatement",
"test": {
"type": "UnaryExpression",
"operator": "!",
"argument": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.2.test.argument.callee.object"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "location"
}
]
}
},
"consequent": {
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "BinaryExpression",
"left": {
"type": "Literal",
"value": "location is not valid: "
},
"operator": "+",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "JSON"
},
"property": {
"type": "Identifier",
"name": "stringify"
}
},
"arguments": [
{
"type": "Identifier",
"name": "location"
}
]
}
}
]
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "UnaryExpression",
"operator": "!",
"argument": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "ion_ast_Primitive"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "value"
}
]
}
},
"consequent": {
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "BinaryExpression",
"left": {
"type": "Literal",
"value": "value is not valid: "
},
"operator": "+",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "JSON"
},
"property": {
"type": "Identifier",
"name": "stringify"
}
},
"arguments": [
{
"type": "Identifier",
"name": "value"
}
]
}
}
]
}
},
"alternate": null
},
{
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "MemberExpression",
"object": {
"type": "ThisExpression"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.0.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "location"
}
}
},
{
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "MemberExpression",
"object": {
"type": "ThisExpression"
},
"property": {
"$ref": "body.13.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.1.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "value"
}
}
},
{
"type": "ExpressionStatement",
"expression": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "freeze"
}
},
"arguments": [
{
"type": "ThisExpression"
}
]
}
}
]
}
}
}
]
}
},
{
"type": "ObjectExpression",
"properties": [
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "types"
},
"kind": "init",
"value": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Set"
},
"arguments": [
{
"type": "ArrayExpression",
"elements": [
{
"type": "Literal",
"value": "ion.ast.Expression"
},
{
"type": "Literal",
"value": "ion.ast.Node"
},
{
"type": "Literal",
"value": "ion.ast.Literal"
}
]
}
]
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "is"
},
"kind": "init",
"value": {
"type": "Literal",
"value": "$ => $ != null && $.constructor.types != null && $.constructor.types.has('ion.ast.Literal')",
"verbatim": "$ => $ != null && $.constructor.types != null && $.constructor.types.has('ion.ast.Literal')"
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "path"
},
"kind": "init",
"value": {
"type": "Literal",
"value": "ion.ast.Literal"
}
}
]
}
]
}
]
}
}
]
},
{
"type": "VariableDeclaration",
"kind": "const",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "ion_ast_Position"
},
"init": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "freeze"
}
},
"arguments": [
{
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "assign"
}
},
"arguments": [
{
"type": "ClassExpression",
"id": {
"type": "Identifier",
"name": "Position"
},
"superClass": null,
"body": {
"type": "ClassBody",
"body": [
{
"type": "MethodDefinition",
"kind": "constructor",
"key": {
"type": "Identifier",
"name": "constructor"
},
"value": {
"type": "FunctionExpression",
"id": null,
"params": [
{
"type": "RestElement",
"argument": {
"type": "Identifier",
"name": "args"
}
}
],
"body": {
"type": "BlockStatement",
"body": [
{
"type": "VariableDeclaration",
"kind": "let",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "line"
},
"init": null
},
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "column"
},
"init": null
}
]
},
{
"type": "ForOfStatement",
"left": {
"type": "VariableDeclaration",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "arg"
}
}
],
"kind": "let"
},
"right": {
"type": "Identifier",
"name": "args"
},
"body": {
"type": "BlockStatement",
"body": [
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!=",
"left": {
"type": "Identifier",
"name": "arg"
},
"right": {
"type": "Literal",
"value": null
}
},
"consequent": {
"type": "BlockStatement",
"body": [
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!==",
"left": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"type": "Identifier",
"name": "line"
}
},
"right": {
"type": "Identifier",
"name": "undefined"
}
},
"consequent": {
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "Identifier",
"name": "line"
},
"right": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.14.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.0.test.left.property"
}
}
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!==",
"left": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"type": "Identifier",
"name": "column"
}
},
"right": {
"type": "Identifier",
"name": "undefined"
}
},
"consequent": {
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "Identifier",
"name": "column"
},
"right": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.14.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.1.test.left.property"
}
}
}
},
"alternate": null
}
]
},
"alternate": null
}
]
}
},
{
"type": "IfStatement",
"test": {
"type": "UnaryExpression",
"operator": "!",
"argument": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "ObjectExpression",
"properties": [
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "is"
},
"kind": "init",
"value": {
"type": "ArrowFunctionExpression",
"id": null,
"params": [
{
"type": "Identifier",
"name": "$"
}
],
"expression": true,
"body": {
"type": "BinaryExpression",
"left": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "ion_Integer"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "$"
}
]
},
"operator": "&&",
"right": {
"type": "BinaryExpression",
"left": {
"type": "Identifier",
"name": "$"
},
"operator": ">=",
"right": {
"type": "Literal",
"value": 1
}
}
}
}
}
]
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "line"
}
]
}
},
"consequent": {
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "BinaryExpression",
"left": {
"type": "Literal",
"value": "line is not valid: "
},
"operator": "+",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "JSON"
},
"property": {
"type": "Identifier",
"name": "stringify"
}
},
"arguments": [
{
"type": "Identifier",
"name": "line"
}
]
}
}
]
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "UnaryExpression",
"operator": "!",
"argument": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "ObjectExpression",
"properties": [
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "is"
},
"kind": "init",
"value": {
"type": "ArrowFunctionExpression",
"id": null,
"params": [
{
"type": "Identifier",
"name": "$"
}
],
"expression": true,
"body": {
"type": "BinaryExpression",
"left": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "ion_Integer"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "$"
}
]
},
"operator": "&&",
"right": {
"type": "BinaryExpression",
"left": {
"type": "Identifier",
"name": "$"
},
"operator": ">=",
"right": {
"type": "Literal",
"value": 0
}
}
}
}
}
]
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "column"
}
]
}
},
"consequent": {
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "BinaryExpression",
"left": {
"type": "Literal",
"value": "column is not valid: "
},
"operator": "+",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "JSON"
},
"property": {
"type": "Identifier",
"name": "stringify"
}
},
"arguments": [
{
"type": "Identifier",
"name": "column"
}
]
}
}
]
}
},
"alternate": null
},
{
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "MemberExpression",
"object": {
"type": "ThisExpression"
},
"property": {
"$ref": "body.14.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.0.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "line"
}
}
},
{
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "MemberExpression",
"object": {
"type": "ThisExpression"
},
"property": {
"$ref": "body.14.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.1.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "column"
}
}
},
{
"type": "ExpressionStatement",
"expression": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "freeze"
}
},
"arguments": [
{
"type": "ThisExpression"
}
]
}
}
]
}
}
}
]
}
},
{
"type": "ObjectExpression",
"properties": [
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "types"
},
"kind": "init",
"value": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Set"
},
"arguments": [
{
"type": "ArrayExpression",
"elements": [
{
"type": "Literal",
"value": "ion.ast.Position"
}
]
}
]
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "is"
},
"kind": "init",
"value": {
"type": "Literal",
"value": "$ => $ != null && $.constructor.types != null && $.constructor.types.has('ion.ast.Position')",
"verbatim": "$ => $ != null && $.constructor.types != null && $.constructor.types.has('ion.ast.Position')"
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "path"
},
"kind": "init",
"value": {
"type": "Literal",
"value": "ion.ast.Position"
}
}
]
}
]
}
]
}
}
]
},
{
"type": "VariableDeclaration",
"kind": "const",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "ion_ast_Module"
},
"init": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "freeze"
}
},
"arguments": [
{
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "assign"
}
},
"arguments": [
{
"type": "ClassExpression",
"id": {
"type": "Identifier",
"name": "Module"
},
"superClass": null,
"body": {
"type": "ClassBody",
"body": [
{
"type": "MethodDefinition",
"kind": "constructor",
"key": {
"type": "Identifier",
"name": "constructor"
},
"value": {
"type": "FunctionExpression",
"id": null,
"params": [
{
"type": "RestElement",
"argument": {
"type": "Identifier",
"name": "args"
}
}
],
"body": {
"type": "BlockStatement",
"body": [
{
"type": "VariableDeclaration",
"kind": "let",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "location"
},
"init": null
},
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "imports"
},
"init": null
},
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "declarations"
},
"init": null
},
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "exports"
},
"init": null
}
]
},
{
"type": "ForOfStatement",
"left": {
"type": "VariableDeclaration",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "arg"
}
}
],
"kind": "let"
},
"right": {
"type": "Identifier",
"name": "args"
},
"body": {
"type": "BlockStatement",
"body": [
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!=",
"left": {
"type": "Identifier",
"name": "arg"
},
"right": {
"type": "Literal",
"value": null
}
},
"consequent": {
"type": "BlockStatement",
"body": [
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!==",
"left": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.0.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "undefined"
}
},
"consequent": {
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "Identifier",
"name": "location"
},
"right": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.0.test.left.property"
}
}
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!==",
"left": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"type": "Identifier",
"name": "imports"
}
},
"right": {
"type": "Identifier",
"name": "undefined"
}
},
"consequent": {
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "Identifier",
"name": "imports"
},
"right": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.15.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.1.test.left.property"
}
}
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!==",
"left": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"type": "Identifier",
"name": "declarations"
}
},
"right": {
"type": "Identifier",
"name": "undefined"
}
},
"consequent": {
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "Identifier",
"name": "declarations"
},
"right": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.15.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.2.test.left.property"
}
}
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!==",
"left": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"type": "Identifier",
"name": "exports"
}
},
"right": {
"type": "Identifier",
"name": "undefined"
}
},
"consequent": {
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "Identifier",
"name": "exports"
},
"right": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.15.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.3.test.left.property"
}
}
}
},
"alternate": null
}
]
},
"alternate": null
}
]
}
},
{
"type": "IfStatement",
"test": {
"type": "UnaryExpression",
"operator": "!",
"argument": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.2.test.argument.callee.object"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "location"
}
]
}
},
"consequent": {
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "BinaryExpression",
"left": {
"type": "Literal",
"value": "location is not valid: "
},
"operator": "+",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "JSON"
},
"property": {
"type": "Identifier",
"name": "stringify"
}
},
"arguments": [
{
"type": "Identifier",
"name": "location"
}
]
}
}
]
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "UnaryExpression",
"operator": "!",
"argument": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "ion_Array"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "imports"
},
{
"type": "Identifier",
"name": "ion_ast_ImportStep"
}
]
}
},
"consequent": {
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "BinaryExpression",
"left": {
"type": "Literal",
"value": "imports is not valid: "
},
"operator": "+",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "JSON"
},
"property": {
"type": "Identifier",
"name": "stringify"
}
},
"arguments": [
{
"type": "Identifier",
"name": "imports"
}
]
}
}
]
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "UnaryExpression",
"operator": "!",
"argument": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "ion_Array"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "declarations"
},
{
"type": "Identifier",
"name": "ion_ast_Declaration"
}
]
}
},
"consequent": {
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "BinaryExpression",
"left": {
"type": "Literal",
"value": "declarations is not valid: "
},
"operator": "+",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "JSON"
},
"property": {
"type": "Identifier",
"name": "stringify"
}
},
"arguments": [
{
"type": "Identifier",
"name": "declarations"
}
]
}
}
]
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "UnaryExpression",
"operator": "!",
"argument": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "ObjectExpression",
"properties": [
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "is"
},
"kind": "init",
"value": {
"type": "ArrowFunctionExpression",
"id": null,
"params": [
{
"type": "Identifier",
"name": "$"
}
],
"expression": true,
"body": {
"type": "BinaryExpression",
"left": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "ion_ast_Declaration"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "$"
}
]
},
"operator": "||",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "ion_Array"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "$"
},
{
"type": "Identifier",
"name": "ion_ast_Declaration"
}
]
}
}
}
}
]
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "exports"
}
]
}
},
"consequent": {
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "BinaryExpression",
"left": {
"type": "Literal",
"value": "exports is not valid: "
},
"operator": "+",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "JSON"
},
"property": {
"type": "Identifier",
"name": "stringify"
}
},
"arguments": [
{
"type": "Identifier",
"name": "exports"
}
]
}
}
]
}
},
"alternate": null
},
{
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "MemberExpression",
"object": {
"type": "ThisExpression"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.0.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "location"
}
}
},
{
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "MemberExpression",
"object": {
"type": "ThisExpression"
},
"property": {
"$ref": "body.15.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.1.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "imports"
}
}
},
{
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "MemberExpression",
"object": {
"type": "ThisExpression"
},
"property": {
"$ref": "body.15.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.2.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "declarations"
}
}
},
{
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "MemberExpression",
"object": {
"type": "ThisExpression"
},
"property": {
"$ref": "body.15.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.3.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "exports"
}
}
},
{
"type": "ExpressionStatement",
"expression": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "freeze"
}
},
"arguments": [
{
"type": "ThisExpression"
}
]
}
}
]
}
}
}
]
}
},
{
"type": "ObjectExpression",
"properties": [
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "types"
},
"kind": "init",
"value": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Set"
},
"arguments": [
{
"type": "ArrayExpression",
"elements": [
{
"type": "Literal",
"value": "ion.ast.Node"
},
{
"type": "Literal",
"value": "ion.ast.Module"
}
]
}
]
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "is"
},
"kind": "init",
"value": {
"type": "Literal",
"value": "$ => $ != null && $.constructor.types != null && $.constructor.types.has('ion.ast.Module')",
"verbatim": "$ => $ != null && $.constructor.types != null && $.constructor.types.has('ion.ast.Module')"
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "path"
},
"kind": "init",
"value": {
"type": "Literal",
"value": "ion.ast.Module"
}
}
]
}
]
}
]
}
}
]
},
{
"type": "VariableDeclaration",
"kind": "const",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "ion_ast_Location"
},
"init": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "freeze"
}
},
"arguments": [
{
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "assign"
}
},
"arguments": [
{
"type": "ClassExpression",
"id": {
"type": "Identifier",
"name": "Location"
},
"superClass": null,
"body": {
"type": "ClassBody",
"body": [
{
"type": "MethodDefinition",
"kind": "constructor",
"key": {
"type": "Identifier",
"name": "constructor"
},
"value": {
"type": "FunctionExpression",
"id": null,
"params": [
{
"type": "RestElement",
"argument": {
"type": "Identifier",
"name": "args"
}
}
],
"body": {
"type": "BlockStatement",
"body": [
{
"type": "VariableDeclaration",
"kind": "let",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "start"
},
"init": null
},
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "end"
},
"init": null
},
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "source"
},
"init": null
}
]
},
{
"type": "ForOfStatement",
"left": {
"type": "VariableDeclaration",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "arg"
}
}
],
"kind": "let"
},
"right": {
"type": "Identifier",
"name": "args"
},
"body": {
"type": "BlockStatement",
"body": [
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!=",
"left": {
"type": "Identifier",
"name": "arg"
},
"right": {
"type": "Literal",
"value": null
}
},
"consequent": {
"type": "BlockStatement",
"body": [
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!==",
"left": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"type": "Identifier",
"name": "start"
}
},
"right": {
"type": "Identifier",
"name": "undefined"
}
},
"consequent": {
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "Identifier",
"name": "start"
},
"right": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.16.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.0.test.left.property"
}
}
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!==",
"left": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"type": "Identifier",
"name": "end"
}
},
"right": {
"type": "Identifier",
"name": "undefined"
}
},
"consequent": {
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "Identifier",
"name": "end"
},
"right": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.16.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.1.test.left.property"
}
}
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!==",
"left": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"type": "Identifier",
"name": "source"
}
},
"right": {
"type": "Identifier",
"name": "undefined"
}
},
"consequent": {
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "Identifier",
"name": "source"
},
"right": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.16.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.2.test.left.property"
}
}
}
},
"alternate": null
}
]
},
"alternate": null
}
]
}
},
{
"type": "IfStatement",
"test": {
"type": "UnaryExpression",
"operator": "!",
"argument": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "ion_ast_Position"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "start"
}
]
}
},
"consequent": {
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "BinaryExpression",
"left": {
"type": "Literal",
"value": "start is not valid: "
},
"operator": "+",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "JSON"
},
"property": {
"type": "Identifier",
"name": "stringify"
}
},
"arguments": [
{
"type": "Identifier",
"name": "start"
}
]
}
}
]
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "UnaryExpression",
"operator": "!",
"argument": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "ion_ast_Position"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "end"
}
]
}
},
"consequent": {
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "BinaryExpression",
"left": {
"type": "Literal",
"value": "end is not valid: "
},
"operator": "+",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "JSON"
},
"property": {
"type": "Identifier",
"name": "stringify"
}
},
"arguments": [
{
"type": "Identifier",
"name": "end"
}
]
}
}
]
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "UnaryExpression",
"operator": "!",
"argument": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "ObjectExpression",
"properties": [
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "is"
},
"kind": "init",
"value": {
"type": "ArrowFunctionExpression",
"id": null,
"params": [
{
"type": "Identifier",
"name": "$"
}
],
"expression": true,
"body": {
"type": "BinaryExpression",
"left": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "ion_String"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "$"
}
]
},
"operator": "&&",
"right": {
"type": "BinaryExpression",
"left": {
"type": "BinaryExpression",
"left": {
"type": "BinaryExpression",
"left": {
"type": "Identifier",
"name": "$"
},
"operator": "===",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "ion_String"
},
"property": {
"type": "Identifier",
"name": "trimmed"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "$"
}
]
}
},
"operator": "&&",
"right": {
"type": "BinaryExpression",
"left": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "ion_String"
},
"property": {
"type": "Identifier",
"name": "length"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "$"
}
]
},
"operator": ">",
"right": {
"type": "Literal",
"value": 0
}
}
},
"operator": "&&",
"right": {
"type": "BinaryExpression",
"left": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "ion_String"
},
"property": {
"type": "Identifier",
"name": "length"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "$"
}
]
},
"operator": "<",
"right": {
"type": "Literal",
"value": 200
}
}
}
}
}
}
]
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "source"
}
]
}
},
"consequent": {
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "BinaryExpression",
"left": {
"type": "Literal",
"value": "source is not valid: "
},
"operator": "+",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "JSON"
},
"property": {
"type": "Identifier",
"name": "stringify"
}
},
"arguments": [
{
"type": "Identifier",
"name": "source"
}
]
}
}
]
}
},
"alternate": null
},
{
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "MemberExpression",
"object": {
"type": "ThisExpression"
},
"property": {
"$ref": "body.16.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.0.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "start"
}
}
},
{
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "MemberExpression",
"object": {
"type": "ThisExpression"
},
"property": {
"$ref": "body.16.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.1.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "end"
}
}
},
{
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "MemberExpression",
"object": {
"type": "ThisExpression"
},
"property": {
"$ref": "body.16.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.2.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "source"
}
}
},
{
"type": "ExpressionStatement",
"expression": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "freeze"
}
},
"arguments": [
{
"type": "ThisExpression"
}
]
}
}
]
}
}
}
]
}
},
{
"type": "ObjectExpression",
"properties": [
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "types"
},
"kind": "init",
"value": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Set"
},
"arguments": [
{
"type": "ArrayExpression",
"elements": [
{
"type": "Literal",
"value": "ion.ast.Location"
}
]
}
]
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "is"
},
"kind": "init",
"value": {
"type": "Literal",
"value": "$ => $ != null && $.constructor.types != null && $.constructor.types.has('ion.ast.Location')",
"verbatim": "$ => $ != null && $.constructor.types != null && $.constructor.types.has('ion.ast.Location')"
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "path"
},
"kind": "init",
"value": {
"type": "Literal",
"value": "ion.ast.Location"
}
}
]
}
]
}
]
}
}
]
},
{
"type": "VariableDeclaration",
"kind": "const",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "ion_Number"
},
"init": {
"type": "Literal",
"value": "Object.freeze({
is(value) {
return typeof value === 'number'
},
integer(value) {
return value - value % 1
},
fraction(value) {
return value % 1
}
})",
"verbatim": "Object.freeze({
is(value) {
return typeof value === 'number'
},
integer(value) {
return value - value % 1
},
fraction(value) {
return value % 1
}
})"
}
}
]
},
{
"type": "VariableDeclaration",
"kind": "const",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "ion_Any"
},
"init": {
"type": "Literal",
"value": "Object.freeze({
is(value) {
return value !== void 0
}
})",
"verbatim": "Object.freeze({
is(value) {
return value !== void 0
}
})"
}
}
]
},
{
"type": "VariableDeclaration",
"kind": "const",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "ion_Type"
},
"init": {
"type": "Literal",
"value": "Object.freeze({
is(value) {
return value != null && typeof value.is === 'function'
}
})",
"verbatim": "Object.freeze({
is(value) {
return value != null && typeof value.is === 'function'
}
})"
}
}
]
},
{
"type": "VariableDeclaration",
"kind": "const",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "ion_ast_Primitive"
},
"init": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "freeze"
}
},
"arguments": [
{
"type": "ObjectExpression",
"properties": [
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "is"
},
"kind": "init",
"value": {
"type": "ArrowFunctionExpression",
"id": null,
"params": [
{
"type": "Identifier",
"name": "$"
}
],
"expression": true,
"body": {
"type": "BinaryExpression",
"left": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "ion_String"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "$"
}
]
},
"operator": "||",
"right": {
"type": "BinaryExpression",
"left": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "ion_Number"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "$"
}
]
},
"operator": "||",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "ion_Boolean"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "$"
}
]
}
}
}
}
}
]
}
]
}
}
]
},
{
"type": "VariableDeclaration",
"kind": "const",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "ion_ast_Property"
},
"init": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "freeze"
}
},
"arguments": [
{
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "assign"
}
},
"arguments": [
{
"type": "ClassExpression",
"id": {
"type": "Identifier",
"name": "Property"
},
"superClass": null,
"body": {
"type": "ClassBody",
"body": [
{
"type": "MethodDefinition",
"kind": "constructor",
"key": {
"type": "Identifier",
"name": "constructor"
},
"value": {
"type": "FunctionExpression",
"id": null,
"params": [
{
"type": "RestElement",
"argument": {
"type": "Identifier",
"name": "args"
}
}
],
"body": {
"type": "BlockStatement",
"body": [
{
"type": "VariableDeclaration",
"kind": "let",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "location"
},
"init": null
},
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "key"
},
"init": null
},
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "value"
},
"init": null
}
]
},
{
"type": "ForOfStatement",
"left": {
"type": "VariableDeclaration",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "arg"
}
}
],
"kind": "let"
},
"right": {
"type": "Identifier",
"name": "args"
},
"body": {
"type": "BlockStatement",
"body": [
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!=",
"left": {
"type": "Identifier",
"name": "arg"
},
"right": {
"type": "Literal",
"value": null
}
},
"consequent": {
"type": "BlockStatement",
"body": [
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!==",
"left": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.0.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "undefined"
}
},
"consequent": {
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "Identifier",
"name": "location"
},
"right": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.0.test.left.property"
}
}
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!==",
"left": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"type": "Identifier",
"name": "key"
}
},
"right": {
"type": "Identifier",
"name": "undefined"
}
},
"consequent": {
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "Identifier",
"name": "key"
},
"right": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.21.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.1.test.left.property"
}
}
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!==",
"left": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"type": "Identifier",
"name": "value"
}
},
"right": {
"type": "Identifier",
"name": "undefined"
}
},
"consequent": {
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "Identifier",
"name": "value"
},
"right": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.21.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.2.test.left.property"
}
}
}
},
"alternate": null
}
]
},
"alternate": null
}
]
}
},
{
"type": "IfStatement",
"test": {
"type": "UnaryExpression",
"operator": "!",
"argument": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.2.test.argument.callee.object"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "location"
}
]
}
},
"consequent": {
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "BinaryExpression",
"left": {
"type": "Literal",
"value": "location is not valid: "
},
"operator": "+",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "JSON"
},
"property": {
"type": "Identifier",
"name": "stringify"
}
},
"arguments": [
{
"type": "Identifier",
"name": "location"
}
]
}
}
]
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "UnaryExpression",
"operator": "!",
"argument": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "ion_ast_Expression"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "key"
}
]
}
},
"consequent": {
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "BinaryExpression",
"left": {
"type": "Literal",
"value": "key is not valid: "
},
"operator": "+",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "JSON"
},
"property": {
"type": "Identifier",
"name": "stringify"
}
},
"arguments": [
{
"type": "Identifier",
"name": "key"
}
]
}
}
]
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "UnaryExpression",
"operator": "!",
"argument": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "ion_ast_Expression"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "value"
}
]
}
},
"consequent": {
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "BinaryExpression",
"left": {
"type": "Literal",
"value": "value is not valid: "
},
"operator": "+",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "JSON"
},
"property": {
"type": "Identifier",
"name": "stringify"
}
},
"arguments": [
{
"type": "Identifier",
"name": "value"
}
]
}
}
]
}
},
"alternate": null
},
{
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "MemberExpression",
"object": {
"type": "ThisExpression"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.0.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "location"
}
}
},
{
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "MemberExpression",
"object": {
"type": "ThisExpression"
},
"property": {
"$ref": "body.21.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.1.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "key"
}
}
},
{
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "MemberExpression",
"object": {
"type": "ThisExpression"
},
"property": {
"$ref": "body.21.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.2.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "value"
}
}
},
{
"type": "ExpressionStatement",
"expression": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "freeze"
}
},
"arguments": [
{
"type": "ThisExpression"
}
]
}
}
]
}
}
}
]
}
},
{
"type": "ObjectExpression",
"properties": [
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "types"
},
"kind": "init",
"value": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Set"
},
"arguments": [
{
"type": "ArrayExpression",
"elements": [
{
"type": "Literal",
"value": "ion.ast.Node"
},
{
"type": "Literal",
"value": "ion.ast.Property"
}
]
}
]
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "is"
},
"kind": "init",
"value": {
"type": "Literal",
"value": "$ => $ != null && $.constructor.types != null && $.constructor.types.has('ion.ast.Property')",
"verbatim": "$ => $ != null && $.constructor.types != null && $.constructor.types.has('ion.ast.Property')"
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "path"
},
"kind": "init",
"value": {
"type": "Literal",
"value": "ion.ast.Property"
}
}
]
}
]
}
]
}
}
]
},
{
"type": "VariableDeclaration",
"kind": "const",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "ion_ast_Reference"
},
"init": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "freeze"
}
},
"arguments": [
{
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "assign"
}
},
"arguments": [
{
"type": "ClassExpression",
"id": {
"type": "Identifier",
"name": "Reference"
},
"superClass": null,
"body": {
"type": "ClassBody",
"body": [
{
"type": "MethodDefinition",
"kind": "constructor",
"key": {
"type": "Identifier",
"name": "constructor"
},
"value": {
"type": "FunctionExpression",
"id": null,
"params": [
{
"type": "RestElement",
"argument": {
"type": "Identifier",
"name": "args"
}
}
],
"body": {
"type": "BlockStatement",
"body": [
{
"type": "VariableDeclaration",
"kind": "let",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "location"
},
"init": null
},
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "name"
},
"init": null
}
]
},
{
"type": "ForOfStatement",
"left": {
"type": "VariableDeclaration",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "arg"
}
}
],
"kind": "let"
},
"right": {
"type": "Identifier",
"name": "args"
},
"body": {
"type": "BlockStatement",
"body": [
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!=",
"left": {
"type": "Identifier",
"name": "arg"
},
"right": {
"type": "Literal",
"value": null
}
},
"consequent": {
"type": "BlockStatement",
"body": [
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!==",
"left": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.0.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "undefined"
}
},
"consequent": {
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "Identifier",
"name": "location"
},
"right": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.0.test.left.property"
}
}
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!==",
"left": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.11.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.1.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "undefined"
}
},
"consequent": {
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "Identifier",
"name": "name"
},
"right": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.11.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.1.test.left.property"
}
}
}
},
"alternate": null
}
]
},
"alternate": null
}
]
}
},
{
"type": "IfStatement",
"test": {
"type": "UnaryExpression",
"operator": "!",
"argument": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.2.test.argument.callee.object"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "location"
}
]
}
},
"consequent": {
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "BinaryExpression",
"left": {
"type": "Literal",
"value": "location is not valid: "
},
"operator": "+",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "JSON"
},
"property": {
"type": "Identifier",
"name": "stringify"
}
},
"arguments": [
{
"type": "Identifier",
"name": "location"
}
]
}
}
]
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "UnaryExpression",
"operator": "!",
"argument": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"$ref": "body.11.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.3.test.argument.callee.object"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "name"
}
]
}
},
"consequent": {
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "BinaryExpression",
"left": {
"type": "Literal",
"value": "name is not valid: "
},
"operator": "+",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "JSON"
},
"property": {
"type": "Identifier",
"name": "stringify"
}
},
"arguments": [
{
"type": "Identifier",
"name": "name"
}
]
}
}
]
}
},
"alternate": null
},
{
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "MemberExpression",
"object": {
"type": "ThisExpression"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.0.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "location"
}
}
},
{
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "MemberExpression",
"object": {
"type": "ThisExpression"
},
"property": {
"$ref": "body.11.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.1.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "name"
}
}
},
{
"type": "ExpressionStatement",
"expression": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "freeze"
}
},
"arguments": [
{
"type": "ThisExpression"
}
]
}
}
]
}
}
}
]
}
},
{
"type": "ObjectExpression",
"properties": [
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "types"
},
"kind": "init",
"value": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Set"
},
"arguments": [
{
"type": "ArrayExpression",
"elements": [
{
"type": "Literal",
"value": "ion.ast.Id"
},
{
"type": "Literal",
"value": "ion.ast.Expression"
},
{
"type": "Literal",
"value": "ion.ast.Node"
},
{
"type": "Literal",
"value": "ion.ast.Reference"
}
]
}
]
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "is"
},
"kind": "init",
"value": {
"type": "Literal",
"value": "$ => $ != null && $.constructor.types != null && $.constructor.types.has('ion.ast.Reference')",
"verbatim": "$ => $ != null && $.constructor.types != null && $.constructor.types.has('ion.ast.Reference')"
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "path"
},
"kind": "init",
"value": {
"type": "Literal",
"value": "ion.ast.Reference"
}
}
]
}
]
}
]
}
}
]
},
{
"type": "VariableDeclaration",
"kind": "const",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "ion_ast_Statement"
},
"init": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "freeze"
}
},
"arguments": [
{
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "assign"
}
},
"arguments": [
{
"type": "ClassExpression",
"id": {
"type": "Identifier",
"name": "Statement"
},
"superClass": null,
"body": {
"type": "ClassBody",
"body": [
{
"type": "MethodDefinition",
"kind": "constructor",
"key": {
"type": "Identifier",
"name": "constructor"
},
"value": {
"type": "FunctionExpression",
"id": null,
"params": [],
"body": {
"type": "BlockStatement",
"body": [
{
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "Literal",
"value": "Statement is abstract"
}
]
}
}
]
}
}
}
]
}
},
{
"type": "ObjectExpression",
"properties": [
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "types"
},
"kind": "init",
"value": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Set"
},
"arguments": [
{
"type": "ArrayExpression",
"elements": [
{
"type": "Literal",
"value": "ion.ast.Node"
},
{
"type": "Literal",
"value": "ion.ast.Statement"
}
]
}
]
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "is"
},
"kind": "init",
"value": {
"type": "Literal",
"value": "$ => $ != null && $.constructor.types != null && $.constructor.types.has('ion.ast.Statement')",
"verbatim": "$ => $ != null && $.constructor.types != null && $.constructor.types.has('ion.ast.Statement')"
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "path"
},
"kind": "init",
"value": {
"type": "Literal",
"value": "ion.ast.Statement"
}
}
]
}
]
}
]
}
}
]
},
{
"type": "VariableDeclaration",
"kind": "const",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "ion_ast_TypeExpression"
},
"init": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "freeze"
}
},
"arguments": [
{
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "assign"
}
},
"arguments": [
{
"type": "ClassExpression",
"id": {
"type": "Identifier",
"name": "TypeExpression"
},
"superClass": null,
"body": {
"type": "ClassBody",
"body": [
{
"type": "MethodDefinition",
"kind": "constructor",
"key": {
"type": "Identifier",
"name": "constructor"
},
"value": {
"type": "FunctionExpression",
"id": null,
"params": [],
"body": {
"type": "BlockStatement",
"body": [
{
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "Literal",
"value": "TypeExpression is abstract"
}
]
}
}
]
}
}
}
]
}
},
{
"type": "ObjectExpression",
"properties": [
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "types"
},
"kind": "init",
"value": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Set"
},
"arguments": [
{
"type": "ArrayExpression",
"elements": [
{
"type": "Literal",
"value": "ion.ast.Expression"
},
{
"type": "Literal",
"value": "ion.ast.Node"
},
{
"type": "Literal",
"value": "ion.ast.TypeExpression"
}
]
}
]
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "is"
},
"kind": "init",
"value": {
"type": "Literal",
"value": "$ => $ != null && $.constructor.types != null && $.constructor.types.has('ion.ast.TypeExpression')",
"verbatim": "$ => $ != null && $.constructor.types != null && $.constructor.types.has('ion.ast.TypeExpression')"
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "path"
},
"kind": "init",
"value": {
"type": "Literal",
"value": "ion.ast.TypeExpression"
}
}
]
}
]
}
]
}
}
]
},
{
"type": "VariableDeclaration",
"kind": "const",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "ion_ast_TypeReference"
},
"init": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "freeze"
}
},
"arguments": [
{
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "assign"
}
},
"arguments": [
{
"type": "ClassExpression",
"id": {
"type": "Identifier",
"name": "TypeReference"
},
"superClass": null,
"body": {
"type": "ClassBody",
"body": [
{
"type": "MethodDefinition",
"kind": "constructor",
"key": {
"type": "Identifier",
"name": "constructor"
},
"value": {
"type": "FunctionExpression",
"id": null,
"params": [
{
"type": "RestElement",
"argument": {
"type": "Identifier",
"name": "args"
}
}
],
"body": {
"type": "BlockStatement",
"body": [
{
"type": "VariableDeclaration",
"kind": "let",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "location"
},
"init": null
},
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "name"
},
"init": null
}
]
},
{
"type": "ForOfStatement",
"left": {
"type": "VariableDeclaration",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "arg"
}
}
],
"kind": "let"
},
"right": {
"type": "Identifier",
"name": "args"
},
"body": {
"type": "BlockStatement",
"body": [
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!=",
"left": {
"type": "Identifier",
"name": "arg"
},
"right": {
"type": "Literal",
"value": null
}
},
"consequent": {
"type": "BlockStatement",
"body": [
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!==",
"left": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.0.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "undefined"
}
},
"consequent": {
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "Identifier",
"name": "location"
},
"right": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.0.test.left.property"
}
}
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!==",
"left": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.11.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.1.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "undefined"
}
},
"consequent": {
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "Identifier",
"name": "name"
},
"right": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.11.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.1.test.left.property"
}
}
}
},
"alternate": null
}
]
},
"alternate": null
}
]
}
},
{
"type": "IfStatement",
"test": {
"type": "UnaryExpression",
"operator": "!",
"argument": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.2.test.argument.callee.object"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "location"
}
]
}
},
"consequent": {
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "BinaryExpression",
"left": {
"type": "Literal",
"value": "location is not valid: "
},
"operator": "+",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "JSON"
},
"property": {
"type": "Identifier",
"name": "stringify"
}
},
"arguments": [
{
"type": "Identifier",
"name": "location"
}
]
}
}
]
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "UnaryExpression",
"operator": "!",
"argument": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"$ref": "body.11.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.3.test.argument.callee.object"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "name"
}
]
}
},
"consequent": {
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "BinaryExpression",
"left": {
"type": "Literal",
"value": "name is not valid: "
},
"operator": "+",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "JSON"
},
"property": {
"type": "Identifier",
"name": "stringify"
}
},
"arguments": [
{
"type": "Identifier",
"name": "name"
}
]
}
}
]
}
},
"alternate": null
},
{
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "MemberExpression",
"object": {
"type": "ThisExpression"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.0.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "location"
}
}
},
{
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "MemberExpression",
"object": {
"type": "ThisExpression"
},
"property": {
"$ref": "body.11.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.1.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "name"
}
}
},
{
"type": "ExpressionStatement",
"expression": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "freeze"
}
},
"arguments": [
{
"type": "ThisExpression"
}
]
}
}
]
}
}
}
]
}
},
{
"type": "ObjectExpression",
"properties": [
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "types"
},
"kind": "init",
"value": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Set"
},
"arguments": [
{
"type": "ArrayExpression",
"elements": [
{
"type": "Literal",
"value": "ion.ast.Reference"
},
{
"type": "Literal",
"value": "ion.ast.Id"
},
{
"type": "Literal",
"value": "ion.ast.Expression"
},
{
"type": "Literal",
"value": "ion.ast.Node"
},
{
"type": "Literal",
"value": "ion.ast.TypeExpression"
},
{
"type": "Literal",
"value": "ion.ast.Expression"
},
{
"type": "Literal",
"value": "ion.ast.Node"
},
{
"type": "Literal",
"value": "ion.ast.TypeReference"
}
]
}
]
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "is"
},
"kind": "init",
"value": {
"type": "Literal",
"value": "$ => $ != null && $.constructor.types != null && $.constructor.types.has('ion.ast.TypeReference')",
"verbatim": "$ => $ != null && $.constructor.types != null && $.constructor.types.has('ion.ast.TypeReference')"
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "path"
},
"kind": "init",
"value": {
"type": "Literal",
"value": "ion.ast.TypeReference"
}
}
]
}
]
}
]
}
}
]
},
{
"type": "VariableDeclaration",
"kind": "const",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "ion_ast_Variable"
},
"init": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "freeze"
}
},
"arguments": [
{
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "assign"
}
},
"arguments": [
{
"type": "ClassExpression",
"id": {
"type": "Identifier",
"name": "Variable"
},
"superClass": null,
"body": {
"type": "ClassBody",
"body": [
{
"type": "MethodDefinition",
"kind": "constructor",
"key": {
"type": "Identifier",
"name": "constructor"
},
"value": {
"type": "FunctionExpression",
"id": null,
"params": [
{
"type": "RestElement",
"argument": {
"type": "Identifier",
"name": "args"
}
}
],
"body": {
"type": "BlockStatement",
"body": [
{
"type": "VariableDeclaration",
"kind": "let",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "location"
},
"init": null
},
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "id"
},
"init": null
},
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "type"
},
"init": {
"type": "Literal",
"value": null
}
},
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "value"
},
"init": {
"type": "Literal",
"value": null
}
},
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "assignable"
},
"init": {
"type": "Literal",
"value": false
}
}
]
},
{
"type": "ForOfStatement",
"left": {
"type": "VariableDeclaration",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "arg"
}
}
],
"kind": "let"
},
"right": {
"type": "Identifier",
"name": "args"
},
"body": {
"type": "BlockStatement",
"body": [
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!=",
"left": {
"type": "Identifier",
"name": "arg"
},
"right": {
"type": "Literal",
"value": null
}
},
"consequent": {
"type": "BlockStatement",
"body": [
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!==",
"left": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.0.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "undefined"
}
},
"consequent": {
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "Identifier",
"name": "location"
},
"right": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.0.test.left.property"
}
}
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!==",
"left": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.1.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "undefined"
}
},
"consequent": {
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "Identifier",
"name": "id"
},
"right": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.1.test.left.property"
}
}
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!==",
"left": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"type": "Identifier",
"name": "type"
}
},
"right": {
"type": "Identifier",
"name": "undefined"
}
},
"consequent": {
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "Identifier",
"name": "type"
},
"right": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.26.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.2.test.left.property"
}
}
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!==",
"left": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"type": "Identifier",
"name": "value"
}
},
"right": {
"type": "Identifier",
"name": "undefined"
}
},
"consequent": {
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "Identifier",
"name": "value"
},
"right": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.26.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.3.test.left.property"
}
}
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!==",
"left": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"type": "Identifier",
"name": "assignable"
}
},
"right": {
"type": "Identifier",
"name": "undefined"
}
},
"consequent": {
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "Identifier",
"name": "assignable"
},
"right": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.26.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.4.test.left.property"
}
}
}
},
"alternate": null
}
]
},
"alternate": null
}
]
}
},
{
"type": "IfStatement",
"test": {
"type": "UnaryExpression",
"operator": "!",
"argument": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.2.test.argument.callee.object"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "location"
}
]
}
},
"consequent": {
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "BinaryExpression",
"left": {
"type": "Literal",
"value": "location is not valid: "
},
"operator": "+",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "JSON"
},
"property": {
"type": "Identifier",
"name": "stringify"
}
},
"arguments": [
{
"type": "Identifier",
"name": "location"
}
]
}
}
]
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "UnaryExpression",
"operator": "!",
"argument": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.3.test.argument.callee.object"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "id"
}
]
}
},
"consequent": {
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "BinaryExpression",
"left": {
"type": "Literal",
"value": "id is not valid: "
},
"operator": "+",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "JSON"
},
"property": {
"type": "Identifier",
"name": "stringify"
}
},
"arguments": [
{
"type": "Identifier",
"name": "id"
}
]
}
}
]
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "UnaryExpression",
"operator": "!",
"argument": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "ObjectExpression",
"properties": [
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "is"
},
"kind": "init",
"value": {
"type": "ArrowFunctionExpression",
"id": null,
"params": [
{
"type": "Identifier",
"name": "$"
}
],
"expression": true,
"body": {
"type": "BinaryExpression",
"left": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "ion_ast_TypeExpression"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "$"
}
]
},
"operator": "||",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "ion_Null"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "$"
}
]
}
}
}
}
]
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "type"
}
]
}
},
"consequent": {
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "BinaryExpression",
"left": {
"type": "Literal",
"value": "type is not valid: "
},
"operator": "+",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "JSON"
},
"property": {
"type": "Identifier",
"name": "stringify"
}
},
"arguments": [
{
"type": "Identifier",
"name": "type"
}
]
}
}
]
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "UnaryExpression",
"operator": "!",
"argument": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "ObjectExpression",
"properties": [
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "is"
},
"kind": "init",
"value": {
"type": "ArrowFunctionExpression",
"id": null,
"params": [
{
"type": "Identifier",
"name": "$"
}
],
"expression": true,
"body": {
"type": "BinaryExpression",
"left": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "ion_ast_Expression"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "$"
}
]
},
"operator": "||",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "ion_Null"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "$"
}
]
}
}
}
}
]
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "value"
}
]
}
},
"consequent": {
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "BinaryExpression",
"left": {
"type": "Literal",
"value": "value is not valid: "
},
"operator": "+",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "JSON"
},
"property": {
"type": "Identifier",
"name": "stringify"
}
},
"arguments": [
{
"type": "Identifier",
"name": "value"
}
]
}
}
]
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "UnaryExpression",
"operator": "!",
"argument": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "ion_Boolean"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "assignable"
}
]
}
},
"consequent": {
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "BinaryExpression",
"left": {
"type": "Literal",
"value": "assignable is not valid: "
},
"operator": "+",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "JSON"
},
"property": {
"type": "Identifier",
"name": "stringify"
}
},
"arguments": [
{
"type": "Identifier",
"name": "assignable"
}
]
}
}
]
}
},
"alternate": null
},
{
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "MemberExpression",
"object": {
"type": "ThisExpression"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.0.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "location"
}
}
},
{
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "MemberExpression",
"object": {
"type": "ThisExpression"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.1.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "id"
}
}
},
{
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "MemberExpression",
"object": {
"type": "ThisExpression"
},
"property": {
"$ref": "body.26.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.2.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "type"
}
}
},
{
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "MemberExpression",
"object": {
"type": "ThisExpression"
},
"property": {
"$ref": "body.26.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.3.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "value"
}
}
},
{
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "MemberExpression",
"object": {
"type": "ThisExpression"
},
"property": {
"$ref": "body.26.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.4.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "assignable"
}
}
},
{
"type": "ExpressionStatement",
"expression": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "freeze"
}
},
"arguments": [
{
"type": "ThisExpression"
}
]
}
}
]
}
}
}
]
}
},
{
"type": "ObjectExpression",
"properties": [
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "types"
},
"kind": "init",
"value": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Set"
},
"arguments": [
{
"type": "ArrayExpression",
"elements": [
{
"type": "Literal",
"value": "ion.ast.Declaration"
},
{
"type": "Literal",
"value": "ion.ast.Node"
},
{
"type": "Literal",
"value": "ion.ast.Variable"
}
]
}
]
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "is"
},
"kind": "init",
"value": {
"type": "Literal",
"value": "$ => $ != null && $.constructor.types != null && $.constructor.types.has('ion.ast.Variable')",
"verbatim": "$ => $ != null && $.constructor.types != null && $.constructor.types.has('ion.ast.Variable')"
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "path"
},
"kind": "init",
"value": {
"type": "Literal",
"value": "ion.ast.Variable"
}
}
]
}
]
}
]
}
}
]
},
{
"type": "VariableDeclaration",
"kind": "const",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "ion_ast_Parameter"
},
"init": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "freeze"
}
},
"arguments": [
{
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "assign"
}
},
"arguments": [
{
"type": "ClassExpression",
"id": {
"type": "Identifier",
"name": "Parameter"
},
"superClass": null,
"body": {
"type": "ClassBody",
"body": [
{
"type": "MethodDefinition",
"kind": "constructor",
"key": {
"type": "Identifier",
"name": "constructor"
},
"value": {
"type": "FunctionExpression",
"id": null,
"params": [
{
"type": "RestElement",
"argument": {
"type": "Identifier",
"name": "args"
}
}
],
"body": {
"type": "BlockStatement",
"body": [
{
"type": "VariableDeclaration",
"kind": "let",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "location"
},
"init": null
},
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "id"
},
"init": null
},
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "type"
},
"init": {
"$ref": "body.26.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.0.declarations.2.init"
}
},
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "value"
},
"init": {
"$ref": "body.26.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.0.declarations.3.init"
}
},
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "assignable"
},
"init": {
"$ref": "body.26.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.0.declarations.4.init"
}
}
]
},
{
"type": "ForOfStatement",
"left": {
"type": "VariableDeclaration",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "arg"
}
}
],
"kind": "let"
},
"right": {
"type": "Identifier",
"name": "args"
},
"body": {
"type": "BlockStatement",
"body": [
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!=",
"left": {
"type": "Identifier",
"name": "arg"
},
"right": {
"type": "Literal",
"value": null
}
},
"consequent": {
"type": "BlockStatement",
"body": [
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!==",
"left": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.0.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "undefined"
}
},
"consequent": {
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "Identifier",
"name": "location"
},
"right": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.0.test.left.property"
}
}
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!==",
"left": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.1.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "undefined"
}
},
"consequent": {
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "Identifier",
"name": "id"
},
"right": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.1.test.left.property"
}
}
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!==",
"left": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.26.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.2.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "undefined"
}
},
"consequent": {
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "Identifier",
"name": "type"
},
"right": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.26.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.2.test.left.property"
}
}
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!==",
"left": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.26.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.3.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "undefined"
}
},
"consequent": {
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "Identifier",
"name": "value"
},
"right": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.26.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.3.test.left.property"
}
}
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "BinaryExpression",
"operator": "!==",
"left": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.26.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.4.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "undefined"
}
},
"consequent": {
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "Identifier",
"name": "assignable"
},
"right": {
"type": "MemberExpression",
"computed": false,
"object": {
"type": "Identifier",
"name": "arg"
},
"property": {
"$ref": "body.26.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.4.test.left.property"
}
}
}
},
"alternate": null
}
]
},
"alternate": null
}
]
}
},
{
"type": "IfStatement",
"test": {
"type": "UnaryExpression",
"operator": "!",
"argument": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.2.test.argument.callee.object"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "location"
}
]
}
},
"consequent": {
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "BinaryExpression",
"left": {
"type": "Literal",
"value": "location is not valid: "
},
"operator": "+",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "JSON"
},
"property": {
"type": "Identifier",
"name": "stringify"
}
},
"arguments": [
{
"type": "Identifier",
"name": "location"
}
]
}
}
]
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "UnaryExpression",
"operator": "!",
"argument": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.3.test.argument.callee.object"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "id"
}
]
}
},
"consequent": {
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "BinaryExpression",
"left": {
"type": "Literal",
"value": "id is not valid: "
},
"operator": "+",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "JSON"
},
"property": {
"type": "Identifier",
"name": "stringify"
}
},
"arguments": [
{
"type": "Identifier",
"name": "id"
}
]
}
}
]
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "UnaryExpression",
"operator": "!",
"argument": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"$ref": "body.26.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.4.test.argument.callee.object"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "type"
}
]
}
},
"consequent": {
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "BinaryExpression",
"left": {
"type": "Literal",
"value": "type is not valid: "
},
"operator": "+",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "JSON"
},
"property": {
"type": "Identifier",
"name": "stringify"
}
},
"arguments": [
{
"type": "Identifier",
"name": "type"
}
]
}
}
]
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "UnaryExpression",
"operator": "!",
"argument": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"$ref": "body.26.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.5.test.argument.callee.object"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "value"
}
]
}
},
"consequent": {
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "BinaryExpression",
"left": {
"type": "Literal",
"value": "value is not valid: "
},
"operator": "+",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "JSON"
},
"property": {
"type": "Identifier",
"name": "stringify"
}
},
"arguments": [
{
"type": "Identifier",
"name": "value"
}
]
}
}
]
}
},
"alternate": null
},
{
"type": "IfStatement",
"test": {
"type": "UnaryExpression",
"operator": "!",
"argument": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"$ref": "body.26.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.6.test.argument.callee.object"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "assignable"
}
]
}
},
"consequent": {
"type": "ThrowStatement",
"argument": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Error"
},
"arguments": [
{
"type": "BinaryExpression",
"left": {
"type": "Literal",
"value": "assignable is not valid: "
},
"operator": "+",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "JSON"
},
"property": {
"type": "Identifier",
"name": "stringify"
}
},
"arguments": [
{
"type": "Identifier",
"name": "assignable"
}
]
}
}
]
}
},
"alternate": null
},
{
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "MemberExpression",
"object": {
"type": "ThisExpression"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.0.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "location"
}
}
},
{
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "MemberExpression",
"object": {
"type": "ThisExpression"
},
"property": {
"$ref": "body.5.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.1.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "id"
}
}
},
{
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "MemberExpression",
"object": {
"type": "ThisExpression"
},
"property": {
"$ref": "body.26.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.2.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "type"
}
}
},
{
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "MemberExpression",
"object": {
"type": "ThisExpression"
},
"property": {
"$ref": "body.26.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.3.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "value"
}
}
},
{
"type": "ExpressionStatement",
"expression": {
"type": "AssignmentExpression",
"operator": "=",
"left": {
"type": "MemberExpression",
"object": {
"type": "ThisExpression"
},
"property": {
"$ref": "body.26.declarations.0.init.arguments.0.arguments.0.body.body.0.value.body.body.1.body.body.0.consequent.body.4.test.left.property"
}
},
"right": {
"type": "Identifier",
"name": "assignable"
}
}
},
{
"type": "ExpressionStatement",
"expression": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "freeze"
}
},
"arguments": [
{
"type": "ThisExpression"
}
]
}
}
]
}
}
}
]
}
},
{
"type": "ObjectExpression",
"properties": [
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "types"
},
"kind": "init",
"value": {
"type": "NewExpression",
"callee": {
"type": "Identifier",
"name": "Set"
},
"arguments": [
{
"type": "ArrayExpression",
"elements": [
{
"type": "Literal",
"value": "ion.ast.Variable"
},
{
"type": "Literal",
"value": "ion.ast.Declaration"
},
{
"type": "Literal",
"value": "ion.ast.Node"
},
{
"type": "Literal",
"value": "ion.ast.Parameter"
}
]
}
]
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "is"
},
"kind": "init",
"value": {
"type": "Literal",
"value": "$ => $ != null && $.constructor.types != null && $.constructor.types.has('ion.ast.Parameter')",
"verbatim": "$ => $ != null && $.constructor.types != null && $.constructor.types.has('ion.ast.Parameter')"
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "path"
},
"kind": "init",
"value": {
"type": "Literal",
"value": "ion.ast.Parameter"
}
}
]
}
]
}
]
}
}
]
},
{
"type": "VariableDeclaration",
"kind": "const",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "ion_Map"
},
"init": {
"type": "Literal",
"value": "(function(){
function createImmutableMap(map) {
return Object.freeze(Object.assign(map, {
clear() {},
delete() {},
set() {}
}))
}
const emptyMap = createImmutableMap(new Map())
return Object.freeze(Object.assign(function ion_Map(...keyValues){
if (arguments.length === 0)
return emptyMap
let map = new Map()
for (let i = 0; i < arguments.length; i += 2) {
// if arguments length is odd then last value will be null
let key = arguments[i + 0]
let value = arguments[i + 1]
if (key === void 0)
key = null
if (value === void 0)
value = null
map.set(key, value)
}
return createImmutableMap(map)
}, {
is(value, KeyType, ValueType) {
// TODO: Once calculated on an instance we could cache the result with a unique Symbol.
if (value !== emptyMap) {
if (!(value instanceof Map))
return false
for (let key of value.keys()) {
if (!KeyType.is(key))
return false
}
for (let value of value.values()) {
if (!ValueType.is(value))
return false
}
}
return true
}
}))
})()",
"verbatim": "(function(){
function createImmutableMap(map) {
return Object.freeze(Object.assign(map, {
clear() {},
delete() {},
set() {}
}))
}
const emptyMap = createImmutableMap(new Map())
return Object.freeze(Object.assign(function ion_Map(...keyValues){
if (arguments.length === 0)
return emptyMap
let map = new Map()
for (let i = 0; i < arguments.length; i += 2) {
// if arguments length is odd then last value will be null
let key = arguments[i + 0]
let value = arguments[i + 1]
if (key === void 0)
key = null
if (value === void 0)
value = null
map.set(key, value)
}
return createImmutableMap(map)
}, {
is(value, KeyType, ValueType) {
// TODO: Once calculated on an instance we could cache the result with a unique Symbol.
if (value !== emptyMap) {
if (!(value instanceof Map))
return false
for (let key of value.keys()) {
if (!KeyType.is(key))
return false
}
for (let value of value.values()) {
if (!ValueType.is(value))
return false
}
}
return true
}
}))
})()"
}
}
]
},
{
"type": "VariableDeclaration",
"kind": "const",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "ion_Integer"
},
"init": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "freeze"
}
},
"arguments": [
{
"type": "ObjectExpression",
"properties": [
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "is"
},
"kind": "init",
"value": {
"type": "ArrowFunctionExpression",
"id": null,
"params": [
{
"type": "Identifier",
"name": "$"
}
],
"expression": true,
"body": {
"type": "BinaryExpression",
"left": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "ion_Number"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "$"
}
]
},
"operator": "&&",
"right": {
"type": "BinaryExpression",
"left": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "ion_Number"
},
"property": {
"type": "Identifier",
"name": "fraction"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "$"
}
]
},
"operator": "===",
"right": {
"type": "Literal",
"value": 0
}
}
}
}
}
]
}
]
}
}
]
},
{
"type": "VariableDeclaration",
"kind": "const",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "ion_Array"
},
"init": {
"type": "Literal",
"value": "(function(){
const emptyArray = Object.freeze([])
return Object.freeze(Object.assign(function ion_Array(){
return emptyArray
}, {
is(value, ValueType) {
// TODO: Once calculated on an instance we could cache the result with a unique Symbol.
if (!Array.isArray(value))
return false
for (let element of value) {
if (!ValueType.is(element))
return false
}
return true
}
}))
})()",
"verbatim": "(function(){
const emptyArray = Object.freeze([])
return Object.freeze(Object.assign(function ion_Array(){
return emptyArray
}, {
is(value, ValueType) {
// TODO: Once calculated on an instance we could cache the result with a unique Symbol.
if (!Array.isArray(value))
return false
for (let element of value) {
if (!ValueType.is(element))
return false
}
return true
}
}))
})()"
}
}
]
},
{
"type": "VariableDeclaration",
"kind": "const",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "ion_constants_$Foo"
},
"init": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "freeze"
}
},
"arguments": [
{
"type": "ObjectExpression",
"properties": [
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "is"
},
"kind": "init",
"value": {
"type": "ArrowFunctionExpression",
"id": null,
"params": [
{
"type": "Identifier",
"name": "$"
}
],
"expression": true,
"body": {
"type": "BinaryExpression",
"left": {
"type": "BinaryExpression",
"left": {
"type": "Identifier",
"name": "$"
},
"operator": "==",
"right": {
"type": "Literal",
"value": 0
}
},
"operator": "||",
"right": {
"type": "BinaryExpression",
"left": {
"type": "Identifier",
"name": "$"
},
"operator": "==",
"right": {
"type": "Literal",
"value": 1
}
}
}
}
}
]
}
]
}
}
]
},
{
"type": "VariableDeclaration",
"kind": "const",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "ion_constants_$Bar"
},
"init": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "freeze"
}
},
"arguments": [
{
"type": "ObjectExpression",
"properties": [
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "is"
},
"kind": "init",
"value": {
"type": "ArrowFunctionExpression",
"id": null,
"params": [
{
"type": "Identifier",
"name": "$"
}
],
"expression": true,
"body": {
"type": "BinaryExpression",
"left": {
"type": "BinaryExpression",
"left": {
"type": "Identifier",
"name": "$"
},
"operator": "==",
"right": {
"type": "Literal",
"value": 2
}
},
"operator": "||",
"right": {
"type": "BinaryExpression",
"left": {
"type": "Identifier",
"name": "$"
},
"operator": "==",
"right": {
"type": "Literal",
"value": 3
}
}
}
}
}
]
}
]
}
}
]
},
{
"type": "VariableDeclaration",
"kind": "const",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "ion_constants_one"
},
"init": {
"type": "Literal",
"value": 1
}
}
]
},
{
"type": "VariableDeclaration",
"kind": "const",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "ion_constants_zero"
},
"init": {
"type": "Literal",
"value": 0
}
}
]
},
{
"type": "VariableDeclaration",
"kind": "const",
"declarations": [
{
"type": "VariableDeclarator",
"id": {
"type": "Identifier",
"name": "ion_constants_Baz"
},
"init": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "freeze"
}
},
"arguments": [
{
"type": "ObjectExpression",
"properties": [
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "is"
},
"kind": "init",
"value": {
"type": "ArrowFunctionExpression",
"id": null,
"params": [
{
"type": "Identifier",
"name": "$"
}
],
"expression": true,
"body": {
"type": "BinaryExpression",
"left": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "ion_constants_$Foo"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "$"
}
]
},
"operator": "||",
"right": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "ion_constants_$Bar"
},
"property": {
"type": "Identifier",
"name": "is"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"name": "$"
}
]
}
}
}
}
]
}
]
}
}
]
},
{
"type": "ExportDefaultDeclaration",
"declaration": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "freeze"
}
},
"arguments": [
{
"type": "ObjectExpression",
"properties": [
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "ion"
},
"value": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "freeze"
}
},
"arguments": [
{
"type": "ObjectExpression",
"properties": [
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "Null"
},
"value": {
"type": "Identifier",
"name": "ion_Null"
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "Boolean"
},
"value": {
"type": "Identifier",
"name": "ion_Boolean"
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "ast"
},
"value": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "freeze"
}
},
"arguments": [
{
"type": "ObjectExpression",
"properties": [
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "Node"
},
"value": {
"type": "Identifier",
"name": "ion_ast_Node"
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "Declaration"
},
"value": {
"type": "Identifier",
"name": "ion_ast_Declaration"
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "ClassDeclaration"
},
"value": {
"type": "Identifier",
"name": "ion_ast_ClassDeclaration"
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "Expression"
},
"value": {
"type": "Identifier",
"name": "ion_ast_Expression"
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "Argument"
},
"value": {
"type": "Identifier",
"name": "ion_ast_Argument"
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "CallExpression"
},
"value": {
"type": "Identifier",
"name": "ion_ast_CallExpression"
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "DotExpression"
},
"value": {
"type": "Identifier",
"name": "ion_ast_DotExpression"
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "Id"
},
"value": {
"type": "Identifier",
"name": "ion_ast_Id"
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "ImportStep"
},
"value": {
"type": "Identifier",
"name": "ion_ast_ImportStep"
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "Literal"
},
"value": {
"type": "Identifier",
"name": "ion_ast_Literal"
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "Position"
},
"value": {
"type": "Identifier",
"name": "ion_ast_Position"
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "Module"
},
"value": {
"type": "Identifier",
"name": "ion_ast_Module"
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "Location"
},
"value": {
"type": "Identifier",
"name": "ion_ast_Location"
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "Primitive"
},
"value": {
"type": "Identifier",
"name": "ion_ast_Primitive"
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "Property"
},
"value": {
"type": "Identifier",
"name": "ion_ast_Property"
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "Reference"
},
"value": {
"type": "Identifier",
"name": "ion_ast_Reference"
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "Statement"
},
"value": {
"type": "Identifier",
"name": "ion_ast_Statement"
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "TypeExpression"
},
"value": {
"type": "Identifier",
"name": "ion_ast_TypeExpression"
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "TypeReference"
},
"value": {
"type": "Identifier",
"name": "ion_ast_TypeReference"
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "Variable"
},
"value": {
"type": "Identifier",
"name": "ion_ast_Variable"
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "Parameter"
},
"value": {
"type": "Identifier",
"name": "ion_ast_Parameter"
}
}
]
}
]
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "String"
},
"value": {
"type": "Identifier",
"name": "ion_String"
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "Number"
},
"value": {
"type": "Identifier",
"name": "ion_Number"
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "Any"
},
"value": {
"type": "Identifier",
"name": "ion_Any"
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "Type"
},
"value": {
"type": "Identifier",
"name": "ion_Type"
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "Map"
},
"value": {
"type": "Identifier",
"name": "ion_Map"
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "Integer"
},
"value": {
"type": "Identifier",
"name": "ion_Integer"
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "Array"
},
"value": {
"type": "Identifier",
"name": "ion_Array"
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "constants"
},
"value": {
"type": "CallExpression",
"callee": {
"type": "MemberExpression",
"object": {
"type": "Identifier",
"name": "Object"
},
"property": {
"type": "Identifier",
"name": "freeze"
}
},
"arguments": [
{
"type": "ObjectExpression",
"properties": [
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "one"
},
"value": {
"type": "Identifier",
"name": "ion_constants_one"
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "zero"
},
"value": {
"type": "Identifier",
"name": "ion_constants_zero"
}
},
{
"type": "Property",
"key": {
"type": "Identifier",
"name": "Baz"
},
"value": {
"type": "Identifier",
"name": "ion_constants_Baz"
}
}
]
}
]
}
}
]
}
]
}
}
]
}
]
}
}
]